• Overview
@angular/router

ErrorBoundaryOptions

interface

Options to configure router error boundary behavior when using withErrorBoundaries.

API

    
      interface ErrorBoundaryOptions {}
    
    

defaultErrorComponent

Type<unknown> | undefined

Default component to render when an error occurs in a route that does not specify its own errorComponent.

onError

((error: Error, details?: ErrorDetails | undefined) => void) | undefined

Optional global callback invoked when any route-level error is caught by the router error boundaries.

The callback runs in the root injection context, so it can use inject to retrieve providers available at the root of the application.

Jump to details