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

x/oak/multipart.ts

A middleware framework for handling HTTP with Deno 🐿️ 🦕
Very Popular
Go to Latest
import * as oak from "https://deno.land/x/oak@v11.0.0/multipart.ts";

Classes

An interface which provides an interface to access the fields of a multipart/form-data body.

Interfaces

When reading a body in full via .read() from a FormDataReader this is what is what the value is resolved, providing a split between any fields, and multi-part files that were provided.

A representation of a file that has been read from a form data body. Based on the FormDataReadOptions that were passed when reading will determine if files are written to disk or not and how they are written to disk. When written to disk, the extension of the file will be determined by the content type, with the .filename property containing the full path to the file.

Options which impact how the form data is decoded for a FormDataReader. All these options have sensible defaults for most applications, but can be modified for different use cases. Many of these options can have an impact on the stability of a server, especially if there is someone attempting a denial of service attack on your server, so be careful when changing the defaults.