Skip to content

UrlTree created by Router.createUrlTree might incorrectly have fragment === undefined #34197

@ferdynton

Description

@ferdynton

🐞 bug report

Affected Package

The issue is caused by package @angular/router, particularly by the method Router.createUrlTree.

Is this a regression?

To my knowledge, no.

Description

When creating a UrlTree using Router.createUrlTree without passing any fragments, the resulting UrlTree contains a fragment === undefined. This does not conform to its type signature.

🔬 Minimal Reproduction

https://stackblitz.com/edit/angular-az3elw

🌍 Your Environment

Angular Version: 8.0.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions