-
Notifications
You must be signed in to change notification settings - Fork 67
Open
Description
Package to replace
form-data
Suggested replacement(s)
In many (if not most) cases, the native FormData (https://nodejs.org/docs/latest/api/globals.html#class-formdata, https://developer.mozilla.org/en-US/docs/Web/API/FormData) could be used instead with no change.
There are some usages of the form-data library that require some code changes though:
- using streams or directly a
Buffer: those need to be turned into aBlob(possibly throughnode:stream/consumers) - the
submit()method: can be replaced withfetch() - a few other specific methods that might not all have replacements (e.g. getBoundary/setBoundary)
Manifest type
native (replaceable by a built-in platform feature)
Rationale
The package mostly duplicates the native FormData
Availability
Node v18 without flags, v21 as non-experimental.
In browsers for 14 years!
Code example (optional)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels