mirror of
https://github.com/denoland/deno.git
synced 2025-07-24 13:44:08 +00:00
refactor(webidl): move prefix & context out of converters options bag (#18931)
This commit is contained in:
parent
d856bfd336
commit
b31cf9fde6
31 changed files with 1042 additions and 964 deletions
|
@ -94,14 +94,16 @@ class DOMException {
|
|||
|
||||
// https://webidl.spec.whatwg.org/#dom-domexception-domexception
|
||||
constructor(message = "", name = "Error") {
|
||||
message = webidl.converters.DOMString(message, {
|
||||
prefix: "Failed to construct 'DOMException'",
|
||||
context: "Argument 1",
|
||||
});
|
||||
name = webidl.converters.DOMString(name, {
|
||||
prefix: "Failed to construct 'DOMException'",
|
||||
context: "Argument 2",
|
||||
});
|
||||
message = webidl.converters.DOMString(
|
||||
message,
|
||||
"Failed to construct 'DOMException'",
|
||||
"Argument 1",
|
||||
);
|
||||
name = webidl.converters.DOMString(
|
||||
name,
|
||||
"Failed to construct 'DOMException'",
|
||||
"Argument 2",
|
||||
);
|
||||
const code = nameToCodeMapping[name] ?? 0;
|
||||
|
||||
this[_message] = message;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue