Describe the bug
History.pushState(state, title, url) and History.replaceState(state, title, url) APIs technically accepts a string or an URL object as the last parameter.
However, while passing URL object, happy-dom throws an exception because of the string comparison methods being used in BrowserFrameURL.getRelativeURL() # line 18
To Reproduce
As described above ☝️
Expected behavior
History APIs should allow for an URL object.
Screenshots
NA
Device:
- OS: [e.g. iOS]
- Browser [e.g. chrome, safari]
- Version [e.g. 22]
Additional context
Describe the bug
History.pushState(state, title, url)andHistory.replaceState(state, title, url)APIs technically accepts astringor anURLobject as the last parameter.However, while passing
URLobject, happy-dom throws an exception because of the string comparison methods being used inBrowserFrameURL.getRelativeURL()# line 18To Reproduce
As described above ☝️
Expected behavior
History APIs should allow for an URL object.
Screenshots
NA
Device:
Additional context