provideRoutes

function

Registers routes.

provideRoutes(routes: Routes): any

Parameters

routes

Type: Routes.

Returns

any

Usage notes

Example

@NgModule({
  imports: [RouterModule.forChild(ROUTES)],
  providers: [provideRoutes(EXTRA_ROUTES)]
})
class MyNgModule {}

© 2010–2019 Google, Inc.
Licensed under the Creative Commons Attribution License 4.0.
https://v6.angular.io/api/router/provideRoutes