Files
servo/components/script_bindings/webidls/AbortSignal.webidl
Taym Haddadi b256914f08 AbortSignal: mark throwIfAborted as [Throws] (#40224)
AbortSignal: mark throwIfAborted as [Throws]

Testing: more AbortSignal passing.
part of #36936

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2025-10-27 21:43:14 +00:00

18 lines
733 B
Plaintext

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
// https://dom.spec.whatwg.org/#abortsignal
[Exposed=*, Pref="dom_abort_controller_enabled"]
interface AbortSignal : EventTarget {
[NewObject] static AbortSignal abort(optional any reason);
[Exposed=(Window,Worker), NewObject] static AbortSignal timeout([EnforceRange] unsigned long long milliseconds);
[NewObject] static AbortSignal _any(sequence<AbortSignal> signals);
readonly attribute boolean aborted;
readonly attribute any reason;
[Throws] undefined throwIfAborted();
attribute EventHandler onabort;
};