The Angular 2 router is strictly connected to the component. It’s also called the Component Router (which is about to come to Angular 1.x as well). The main purpose of it is to have routable components. They are often smart components that are fetching resources from the API.
Let’s start with adding a router to the app. The very beginning is to add the general URL to that app which is accessible. This usually ends up with
/ as the entrance point, but you may need to change it such as when you are trying to connect Angular 2 with an existing app.
The entire application is openly available at https://github.com/flauc/angular2-edge-app.
The base href is achieved by adding the element