<head>
tag of index.html:In the demos we use a script tag to set the base tag. In a real application it must be set as above.
Routes
type is an array of routes that defines the routing for the application. This is where we can set up the expected paths, the components we want to use and what we want our application to understand them as.Routes
array definition:RouterModule.forRoot
takes the Routes
array as an argument and returns a configured router module. The following sample shows how we import this module in an app.routes.ts
file.