This post will cover the step needed to take the angular universal app to the production server. This post assumes that you have running angular universal application and which is generated by angular CLI. Now open your terminal or command prompt, point the cursor to the project folder and run the build command as shown […]
This tutorial I will show you Nginx installation and configuration steps to serve Angular application in production. I am gonna use Ubuntu 16.04 operating system. Install and Configure Nginx for Angular First update the apt-get package lists and then install Nginx using apt-get: Then open the default file to configure server which is located in […]
In this article, you will learn how to use cascading DropDownList using Angular application. In following tutorial you gonna use Angular CLI to create an application. Here is the official website of Angular CLI. Why Angular CLI The Angular CLI makes it easy to create an application that already works, right out of the box. […]
Inside the root app component, Inject the Router and subscribe to route change events and detect the NavigationStart event with the event type instance, its called NavigationStart. With the Renderer2 class we can add and remove class to the body as shown below.
Angular 2 provide different ways to apply class to the elements based on certain conditions. In this post I would like to show you couple of ways to conditionally applying class to a DOM element in Angular 2 with ngClass. Methods to Apply CSS Classes Conditionally