• Overview
@angular/router

NavigationError

Class

An event triggered when a navigation fails due to an unexpected error.

API

  
    class NavigationError extends RouterEvent {}
  
  

constructor

NavigationError
@paramidnumber
@paramurlstring
@paramerrorany
@paramtargetRouterStateSnapshot | undefined

The target of the navigation when the error occurred.

Note that this can be undefined because an error could have occurred before the RouterStateSnapshot was created for the navigation.

error

any

toString

string
@returnsstring

id

number

A unique ID that the router assigns to every router navigation.

url

string

The URL that is the destination for this navigation.

Jump to details