Gathering detailed insights and metrics for express-formidable-v2
Gathering detailed insights and metrics for express-formidable-v2
Gathering detailed insights and metrics for express-formidable-v2
Gathering detailed insights and metrics for express-formidable-v2
A Folk of express-formidable An Express middleware of Formidable that just works.
npm install express-formidable-v2
Typescript
Module System
Min. Node Version
Node Version
NPM Version
JavaScript (100%)
Total Downloads
18,636
Last Day
6
Last Week
47
Last Month
235
Last Year
4,571
MIT License
2 Stars
61 Commits
2 Branches
1 Contributors
Updated on May 26, 2024
Minified
Minified + Gzipped
Latest Version
2.2.1
Package Id
express-formidable-v2@2.2.1
Unpacked Size
6.16 kB
Size
2.78 kB
File Count
5
NPM Version
7.19.1
Node Version
16.5.0
Cumulative downloads
Total Downloads
1
This is Folk of express-formidable An Express middleware of Formidable that just works.
Express is a fast, unopinionated, minimalist web framework for Node.js.
Formidable is a Node.js module
for parsing form data, including multipart/form-data
file upload.
So, express-formidable
is something like a bridge between them,
specifically an Express middleware implementation of Formidable.
It aims to just work.
npm install express-formidable-v2
1const express = require('express'); 2const formidableMiddleware = require('express-formidablei-v2'); 3 4var app = express(); 5 6app.use(formidableMiddleware()); 7 8app.post('/upload', (req, res) => { 9 req.fields; // contains non-file fields 10 req.files; // contains files 11});
And that's it.
express-formidable can basically parse form types Formidable can handle,
including application/x-www-form-urlencoded
, application/json
, and
multipart/form-data
.
1app.use(formidableMiddleware(opts));
opts
are options which can be set to form
in Formidable. For example:
1app.use(formidableMiddleware({
2 encoding: 'utf-8',
3 uploadDir: '/my/dir',
4 multiples: true, // req.files to be arrays of files
5});
For the detail, please refer to the Formidable API.
1app.use(formidableMiddleware(opts, events));
events
is an array of json with two field:
Field | Description |
---|---|
event | The event emitted by the form of formidable. A complete list of all the possible events, please refer to the Formidable Events |
action | The callback to execute. The signature is function (req, res, next, ...formidable_parameters) |
For example:
1const events = [ 2 { 3 event: 'fileBegin', 4 action: function (req, res, next, name, file) { /* your callback */ } 5 }, 6 { 7 event: 'field', 8 action: function (req, res, next, name, value) { /* your callback */ } 9 } 10];
Unless an error
event are provided by the events
array parameter, it will handle by the standard next(error)
.
git clone https://github.com/Abderrahman-byte/express-formidable-v2
cd express-formidable
npm install
To lint and test:
npm test
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no SAST tool detected
Details
Reason
Found 0/30 approved changesets -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
28 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-06-30
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn MoreLast Day
100%
6
Compared to previous day
Last Week
-13%
47
Compared to previous week
Last Month
1.7%
235
Compared to previous month
Last Year
-25.5%
4,571
Compared to previous year