
Add a partial implementation of HTML5 Worker API. Messages can be sent from the inner context externally.
16 lines
434 B
Text
16 lines
434 B
Text
[Exposed=(Window)]
|
|
interface Worker : EventTarget {
|
|
constructor(DOMString scriptURL, optional WorkerOptions options = {});
|
|
|
|
undefined terminate();
|
|
undefined postMessage(any message, optional any transfer);
|
|
|
|
attribute EventHandler onmessage;
|
|
attribute EventHandler onmessageerror;
|
|
};
|
|
|
|
dictionary WorkerOptions {
|
|
USVString type = "classic";
|
|
USVString credentials = "same-origin";
|
|
DOMString name = "";
|
|
};
|