9.0.5 • Published 2 years ago

@mole-inc/cwebp-bin v9.0.5

Weekly downloads
4
License
MIT
Repository
github
Last release
2 years ago

cwebp-bin Node CI

WebP is a new image format that provides lossless and lossy compression for images on the web. WebP lossless images are 26% smaller in size compared to PNGs. WebP lossy images are 25-34% smaller in size compared to JPEG images at equivalent SSIM index.

You probably want imagemin-webp instead.

Downloads Version codecov

Install

$ npm install @mole-inc/cwebp-bin

Usage

import {execFile} from 'child_process';
import {cwebpBin} from '@mole-inc/cwebp-bin';

execFile(cwebpBin.path, ['input.png', '-o', 'output.webp'], err => {
	if (err) {
		throw err;
	}

	console.log('Image is converted!');
});

CLI

$ npm install --global @mole-inc/cwebp-bin
$ cwebp --help

License

This is a fork of imagemin/cwebp-bin licensed under the MIT License.

see license file and vendor/cwebp-license.txt file.