1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 18:27:35 +00:00

LibWeb/URL: Add strip_trailing_spaces_from_an_opaque_path()

Also remove 2 FIXMEs by including this function.
This commit is contained in:
Kemal Zebari 2023-09-10 16:50:29 -07:00 committed by Andrew Kaster
parent ce549eb92a
commit 824c54acaf
4 changed files with 58 additions and 2 deletions

View file

@ -0,0 +1,14 @@
<script src="../include.js"></script>
<script>
test(() => {
let url = new URL("scheme:foobar ?well=hello");
println(`pathname => '${url.pathname}'`);
url.search = "";
println(`pathname => '${url.pathname}'`);
url = new URL("scheme:baz #friends");
println(`pathname => '${url.pathname}'`);
url.hash = "";
println(`pathname => '${url.pathname}'`);
});
</script>