Socket
Book a DemoInstallSign in
Socket

cwebp-bin

Package Overview
Dependencies
Maintainers
6
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cwebp-bin

cwebp wrapper that makes it seamlessly available as a local dependency

latest
Source
npmnpm
Version
8.0.0
Version published
Weekly downloads
121K
22.87%
Maintainers
6
Weekly downloads
 
Created
Source

cwebp-bin GitHub Actions Status

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.

Install

$ npm install cwebp-bin

Usage

import {execFile} from 'node:child_process';
import cwebp from 'cwebp-bin';

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

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

CLI

$ npm install --global cwebp-bin
$ cwebp --help

License

MIT © Imagemin

Keywords

imagemin

FAQs

Package last updated on 06 May 2022

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