Deployment
In this section you will learn about how to deploy your application on the live server. Please read the documentation carefully.
Last updated
In this section you will learn about how to deploy your application on the live server. Please read the documentation carefully.
Last updated
For the simple deployment, follow the steps given below:
Step 1: Make a production build, by running the command given below:
It will create the dist
folder, that contains the production build files.
Step 2: Now you just need to upload the dist
files on to the server.
Step 3: Configure the server to redirect requests for missing files to index.html
. Learn more about server-side redirects .
It is Ahead-of-Time (AOT) compiler, which compiles your app at build time. For AOT compilation, include the --aot
option with the commands.
To get more help on the angular-cli
use ng --help
or for more details, please visit .
We use the following command to build a production build. It will reduce the build size by optimizing the code at build time.
If you want to make your production build in different folder or sub directory. Like, if you want that the template run on the test.com/output
rather then test.com
then you need to follow the steps given below:
Step 1: Open the src->index.html
file & search for the base tag:
and set your path as per requirement like:
After that you need to create a new sub folder with the name output
and upload all the files in this folder.