In this video I demonstrate how to create a new Angular 2 project with Routing and host in a SharePoint Document Library. This technique enables rapid development with Angular CLI’s http://localhost:4200 live preview website and simple publish to /dist/ for hosting on SharePoint.
Cheers!

Video
Screenshots



Video Content
- Angular CLI Documentation
- ng -v
- ng new sproute –routing
- ng g c route1
- ng g c route2
- ng g c route3
- code .
- Visual Studio Code
- [index.html] remove Base Href
- [app-routing.module.ts] Import Components, populate Route map with {path; component}, and {useHash:true}
- ng serve
- ng build