-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: avoid URL-confusing default pathname in baseUrl (#565)
Fixes #517 When not set explicitly, the router constructor discovers `baseUrl` using the `<base href>` value and initial document URL. However, only the pathname from the discovered base URL was taken for the default value of the `baseUrl` property. In case of initial pathname starting with double slash `//`, such a value was then throwing `Invalid URL` error when used as the URL constructor’s first argument. This changes the default value discovery of `baseUrl`, so that it uses an actual URL instead of only pathname to avoid throwing errors.
- Loading branch information
Showing
4 changed files
with
48 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters