Skip to content

Provide way to identify Router navigation errors in the global ErrorHandler #48902

@CSchulz

Description

@CSchulz

Which @angular/* package(s) are relevant/related to the feature request?

router

Description

This is a followup of #48759, especially #48759 (comment).

The use case of the own ErrorHandler in the Router prevents delegating the error to the @angular/core ErrorHandler.
In this scenario normally the NavigationService handles all navigation errors.
All other errors should be handled by the GlobalErrorHandler.

https://stackblitz.com/edit/angular-dob9kc?file=src/main.ts

Proposed solution

Keep the existing possibility to overwrite the behavior how the router handles a NavigationError.

Alternatives considered

none.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentarea: router

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions