blob: f637d05ddcbb42c8d409b80d54727d855f2a316e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
addEventListener("error", function(e) {
var obj = {};
for (var prop of ["message", "filename", "lineno"]) {
obj[prop] = e[prop];
}
obj.type = "event";
postMessage(obj);
});
onerror = function(message, filename, lineno) {
var obj = {
message,
filename,
lineno,
type: "callback",
};
postMessage(obj);
return false;
};
throw new Error("workerhello");
|