Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/evt/lib/index.ts>dom.FormData

💧EventEmitter's typesafe replacement
Go to Latest
interface dom.FormData
import { type dom } from "https://deno.land/x/evt@v2.4.16/lib/index.ts";
const { FormData } = dom;

Provides a way to easily construct a set of key/value pairs representing form fields and their values, which can then be easily sent using the XMLHttpRequest.send() method. It uses the same format a form would use if the encoding type were set to "multipart/form-data".

Methods

append(
name: string,
value: string | Blob,
fileName?: string,
): void
delete(name: string): void
get(name: string): FormDataEntryValue | null
getAll(name: string): FormDataEntryValue[]
has(name: string): boolean
set(
name: string,
value: string | Blob,
fileName?: string,
): void
forEach(callbackfn: (
key: string,
parent: FormData,
) => void
, thisArg?: any
): void