LibWeb: Set correct prototype for WorkerLocation

This commit is contained in:
Tim Ledbetter 2024-07-28 19:14:45 +01:00 committed by Andreas Kling
commit 354e5a6624
Notes: github-actions[bot] 2024-07-28 19:41:19 +00:00
5 changed files with 20 additions and 0 deletions

View file

@ -0,0 +1,11 @@
<script src="../include.js"></script>
<script>
asyncTest(done => {
let work = new Worker("Worker-location.js");
work.onmessage = (evt) => {
const locationURL = new URL(evt.data);
println(`location global object URL final segment: ${locationURL.pathname.split('/').pop()}`);
done();
};
});
</script>

View file

@ -0,0 +1 @@
postMessage(location.toString());