docs: update an example in the RouterEvent description (#50526)

PR Close #50526
This commit is contained in:
Nikolas Kazepis 2023-05-31 11:55:29 +03:00 committed by Pawel Kozlowski
parent ad82f3ab47
commit ee073cdfae

View file

@ -58,7 +58,7 @@ export const enum EventType {
* class MyService {
* constructor(public router: Router) {
* router.events.pipe(
* filter((e: Event): e is RouterEvent => e instanceof RouterEvent)
* filter((e: Event | RouterEvent): e is RouterEvent => e instanceof RouterEvent)
* ).subscribe((e: RouterEvent) => {
* // Do something
* });