New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

imagetune

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

imagetune

Image Tune takes image files and handles resize and conversion in the browser prior to upload, saving server processing time and storage space while reducing upload times.

  • 1.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

Image Tune

Image Tune takes image files and handles resize and conversion in the browser prior to upload, saving server processing time and storage space while reducing upload times.

Now you're users can upload large images from modern smartphones or DSLR cameras quickly and efficiently as the client handles the conversion of the image to a web-appropriate size. Perfect for user profiles, social media images and more.

Example: https://connerfritz.github.io/imagetune/

Usage

var ImageTune = require('imagetune');
document.getElementById("image-file").addEventListener("change", function(evt) {
  var file = evt.target.files[0];
  var options = {
    type: 'png', 
    quality: 80, 
    height: 250, 
    width: 250
  };
  ImageTune.tune(file, options).then(function (imageData) {
    document.body.getElementById("image-data").setAttribute("value", imageData);
  });
});

Options

NameDescriptionDefault
widthDesired width of result image in pixels200
heightDesired height of result image in pixels200
qualityImage quality value, changes file size (1-100)100
typeImage format type (png, jpg, gif)jpg
modeScale mode (crop or scale)scale

Keywords

FAQs

Package last updated on 03 Apr 2019

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