pngcrush bin-wrapper that makes it seamlessly available as a local dependency
JavaScript
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib
test
vendor
.editorconfig
.gitattributes
.gitignore
.travis.yml
cli.js
index.js
license
package.json
readme.md

readme.md

pngcrush-bin Build Status

pngcrush is an optimizer which main purpose is to reduce the size of the PNG IDAT datastream by trying various compression levels an PNG filter methods

You probably want imagemin-pngcrush instead.

Install

$ npm install --save pngcrush-bin

Usage

const {execFile} = require('child_process');
const pngcrush = require('pngcrush-bin');

execFile(pngcrush, ['-reduce', '-brute', 'input.png', 'output.png'], err => {
	console.log('Image minified');
});

CLI

$ npm install --global pngcrush-bin
$ pngcrush --help

License

MIT © Imagemin