New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

imagerequest

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

imagerequest

Image request handler with on demand resizing using ImageMagick.

latest
Source
npmnpm
Version
0.0.1
Version published
Maintainers
1
Created
Source

ImageRequest

Image request handler for Node.js with on demand resizing using ImageMagick.

Explanation

ImageRequest is a small module that you hook up to your Node.js HTTP server to handle image requests. ImageRequest will then handle image delivery and on demand resizing for you.

Usage

To use ImageRequest with for example Express do something like this:

var ir = require('image-request');
app.get('photos/:size/:img', ir({
  src: __dirname + '/photos',
}));

Then when someone requests for example photos/small/picture.jpg a resized version of the original picture.jpg will be delivered. The resized version is stored on disk an reused for subsequent requests.

Installation

Install with npm install imagerequest

You will also need to have ImageMagick installed on your system.

Note

This project is very new, and very rough around the edges. It's probably not very well coded at this moment. And a lot of functionality is only half assed or not at all implemented even though the source suggestes otherwise.

Please try it out if you want to. As always, pull requests much appreciated.

Currently unimplemented

  • Real error reporting and error handling
  • Blocking of upscaling
  • Documentation
  • Other stuff

License

See LICENSE

FAQs

Package last updated on 01 Jul 2012

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