Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

images-upload-middleware

Package Overview
Dependencies
Maintainers
2
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

images-upload-middleware

express middleware for images upload

  • 1.1.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
3
decreased by-57.14%
Maintainers
2
Weekly downloads
 
Created
Source

images-upload-middleware

NPM

Express middleware for images upload

Usage

npm i -S images-upload-middleware

Prams

  • savePath: string - path where you want to save images;
  • servePath: string - serve path;
  • multiple: boolean - allows to upload a bunch of images;
  • rename: boolean - if false, then do not rename image default: true;

Examples

import express from 'express';
import imagesUpload from 'images-upload-middleware';

const app = express();

app.use('/static', express.static('./static'));

app.post('/multiple', imagesUpload(
	'./static/multipleFiles',
	'http://localhost:8080/static/multipleFiles',
	true
));

app.post('/notmultiple', imagesUpload(
	'./static/files',
	'http://localhost:8080/static/files'
));

app.post('/notrename', imagesUpload(
	'./static/originalNameFiles',
	'http://localhost:8080/static/originalNameFiles',
	true,
	false
));

app.listen(8080);

Keywords

FAQs

Package last updated on 21 Dec 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc