Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: [#1568] Accept stringable objects in Location.assign and Location.replace #1569

Merged
merged 3 commits into from
Nov 6, 2024

Conversation

silverwind
Copy link
Contributor

@silverwind silverwind commented Oct 21, 2024

Fixes: #1568
Related: mdn/content#36432

As Typescript does not have a suitable type for stringable things, I think having URL is the best we can do and it matches the Typescript DOM types as well.

@silverwind silverwind changed the title fix: [#1568] Accept URL in Location.assign and Location.replace fix: [#1568] Accept stringable objects in Location.assign and Location.replace Oct 28, 2024
Copy link
Owner

@capricorn86 capricorn86 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution @silverwind! ⭐

I agree that URL is probably the best we can do, specially if the Typescript DOM types uses it.

@capricorn86 capricorn86 merged commit f5e1722 into capricorn86:master Nov 6, 2024
3 checks passed
@silverwind silverwind deleted the assign branch November 7, 2024 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Location.assign and Location.replace should accept URL object for url
2 participants