Introduction
This guide covers deploying Angular applications on Shard Cloud.Creating Your Project
Ensure you have Node.js and npm installed.Installing Angular CLI
Creating a New Project
Building Your Project
Build the production output:dist/ folder with optimized files.
Serving Your Angular App
Angular apps are static files that need a server:Using serve
Using Express
Create aserver.js file:
server.js
Replace
my-angular-app with your actual project name in the path.Shard Cloud Configuration
Create a.shardcloud file:
.shardcloud
Deploying
Upload to Shard Cloud
Go to Shard Cloud Dashboard and upload.
Additional Resources
Visit the official Angular documentation for more information.Troubleshooting
Build fails with memory errors
Build fails with memory errors
Increase
MEMORY to at least 1024MB for Angular builds.Routes not working (404)
Routes not working (404)
Ensure your server serves
index.html for all routes.