@cjser/jpegoptim-bin
v7.1.0-cjser.2
Published
jpegoptim wrapper that makes it seamlessly available as a local dependency
Downloads
83
Maintainers
Readme
jpegoptim-bin 
jpegoptim is a utility for optimizing JPEG files that provides lossless optimization (based on optimizing the Huffman tables) and "lossy" optimization based on setting a maximum quality factor
You probably want imagemin-jpegoptim instead.
Install
$ npm install jpegoptim-binMake sure you have the correct version of libjpeg. See jpegoptim's README for more information.
Usage
import {execFile} from 'child_process';
import jpegoptim from 'jpegoptim-bin';
const args = [
'--overwrite',
'--strip-all',
'--strip-iptc',
'--strip-icc',
'--all-progressive',
'--dest=build',
'input.jpg'
];
execFile(jpegoptim, args, error => {
console.log('Image minified');
});CLI
$ npm install --global jpegoptim-bin$ jpegoptim --helpLicense
MIT © Imagemin
cjser
This package is a CommonJS-compatible build generated by cjser for projects that still need require() support. The source version matches the original npm package version, with a cjser prerelease suffix for this generated build.
Original repository: https://github.com/imagemin/jpegoptim-bin
