FormDataEntry.h 461 B

123456789101112131415161718192021222324
  1. /*
  2. * Copyright (c) 2023, Kenneth Myhra <kennethmyhra@serenityos.org>
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. #pragma once
  7. #include <AK/String.h>
  8. #include <AK/Variant.h>
  9. #include <LibJS/Heap/Handle.h>
  10. #include <LibWeb/Forward.h>
  11. namespace Web::XHR {
  12. // https://xhr.spec.whatwg.org/#formdataentryvalue
  13. using FormDataEntryValue = Variant<JS::Handle<FileAPI::File>, String>;
  14. struct FormDataEntry {
  15. String name;
  16. FormDataEntryValue value;
  17. };
  18. }