FetchMethod.h 544 B

1234567891011121314151617181920
  1. /*
  2. * Copyright (c) 2022-2023, Linus Groh <linusg@serenityos.org>
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. #pragma once
  7. #include <AK/Forward.h>
  8. #include <LibJS/Forward.h>
  9. #include <LibJS/Heap/GCPtr.h>
  10. #include <LibWeb/Fetch/Request.h>
  11. #include <LibWeb/WebIDL/Promise.h>
  12. namespace Web::Fetch {
  13. JS::NonnullGCPtr<JS::Promise> fetch(JS::VM&, RequestInfo const& input, RequestInit const& init = {});
  14. void abort_fetch(JS::Realm&, WebIDL::Promise const&, JS::NonnullGCPtr<Infrastructure::Request>, JS::GCPtr<Response>, JS::Value error);
  15. }