express-multiparty-parser
TypeScript icon, indicating that this package has built-in type declarations

0.0.1 • Public • Published

Express Multiparty Parser

A package that parses an express request fields but also files to base64 strings using multiparty

Installation

    # With npm

    npm install express-multiparty-parser
    # Or with yarn

    yarn add express-multiparty-parser

Usage

import express from "express";
import { parseMultipartData } from "express-multiparty-parser";

const app = express();

app.get("/", async function (req, res) {
  let data;

  try {
    data = await parseMultipartData(req);
  } catch (error) {
    console.error(error);
  }

  res.status(200).json(data);
});

app.listen(3000, () => console.log("Server running on port 3000"));

Package Sidebar

Install

npm i express-multiparty-parser

Weekly Downloads

2

Version

0.0.1

License

ISC

Unpacked Size

27.9 kB

Total Files

12

Last publish

Collaborators

  • nkpremices