RouterEvent
class
Base for events the Router goes through, as opposed to events tied to a specific Route. RouterEvent
s will only be fired one time for any given navigation.
class RouterEvent { constructor(id: number, url: string) id: number url: string }
Subclasses
Description
Example:
class MyService { constructor(public router: Router, logger: Logger) { router.events.pipe( filter(e => e instanceof RouterEvent) ).subscribe(e => { logger.log(e.id, e.url); }); } }
Constructor
|
id | number | |
url | string |
Properties
Property | Description |
---|---|
id: number | Declared in constructor. |
url: string | Declared in constructor. |
© 2010–2019 Google, Inc.
Licensed under the Creative Commons Attribution License 4.0.
https://v7.angular.io/api/router/RouterEvent