LibWeb: Hook TrustedTypes to the SharedWorkers api

This commit is contained in:
Tete17 2025-10-06 18:00:37 +02:00 committed by Luke Wilde
parent bd4e3fd3e0
commit e6ac064a34
Notes: github-actions[bot] 2025-10-13 12:23:30 +00:00
4 changed files with 17 additions and 8 deletions

View file

@ -2,12 +2,12 @@
#import <HTML/AbstractWorker.idl>
#import <HTML/MessagePort.idl>
#import <HTML/Worker.idl>
#import <TrustedTypes/TrustedScriptURL.idl>
// https://html.spec.whatwg.org/multipage/workers.html#sharedworker
[Exposed=Window]
interface SharedWorker : EventTarget {
// FIXME: "DOMString scriptURL" should be "(TrustedScriptURL or USVString) scriptURL".
constructor(DOMString scriptURL, optional (DOMString or WorkerOptions) options = {});
constructor((TrustedScriptURL or Utf16USVString) scriptURL, optional (DOMString or WorkerOptions) options = {});
readonly attribute MessagePort port;
};