Skip to content

Instantly share code, notes, and snippets.

Created Feb 12, 2022
What would you like to do?
upload file and form field
var express = require('express')
var app = express()
const multer = require('multer')
const upload = multer({ dest: 'uploads/' })
// POST /login gets urlencoded bodies'/sample', upload.single('uploaded_file'), function (req, res) {
res.send( req.body)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment