…into your root Angular-CLI project directory you’d like to add Universal into, and run the following schematic.
Since we have created angular application, we need to modify this application to make it production ready. We are going to create few components with following commands.
…lly index.html page is served from express server for all the URL paths and that index.html page is passed through some express view engine which injects HTML into <app-root></app-root>, based on current ro…
h components t…rd interactions. It’s intended to be used with components that correspond to a role="menu” or role="listbox” pattern.
h components t
… locations, and provides many constructs which allow you to deal with highly powerful variables and objects.
Great so we created all the things our store needs, but we have one thing missing yet, putting everything together. I am going to do it in the app module, but you can apply the same in the core …
The first two steps are necessary while the steps 3 and 4 I highly recommend them but they are not mandatory.
And that’s it… creating actions is simple. Let’s take a look at how the config actions look (store/actions/config.actions.ts):
You would have an efficient Nginx server with great performance for your static final (compiled) files.…
Another way to do it would be to do not add your compiled code to your Git repository and build your app every time you are going to deploy.