1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 01:27:34 +00:00

LibWeb/HTML: Port Window.fetch() to IDL

This commit is contained in:
Linus Groh 2023-03-07 18:15:52 +00:00
parent a2fb3a1653
commit 5cc6b1c4db
12 changed files with 22 additions and 389 deletions

View file

@ -1,3 +1,6 @@
#import <Fetch/Request.idl>
#import <Fetch/Response.idl>
// https://html.spec.whatwg.org/multipage/webappapis.html#windoworworkerglobalscope
interface mixin WindowOrWorkerGlobalScope {
[Replaceable] readonly attribute USVString origin;
@ -25,4 +28,7 @@ interface mixin WindowOrWorkerGlobalScope {
// structured cloning
// FIXME: any structuredClone(any value, optional StructuredSerializeOptions options = {});
// https://fetch.spec.whatwg.org/#fetch-method
[NewObject] Promise<Response> fetch(RequestInfo input, optional RequestInit init = {});
};