Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

broccoli-webp

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

broccoli-webp

JPEG/PNG to WebP converter for Broccoli

  • 0.1.8
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

broccoli-webp npm version npm downloads Build Status Dependency Status Unlicense

This Broccoli plugin converts JPEG/PNG files to WebP.

Installation

Install just like any other broccoli plugin:

npm install --save-dev broccoli-webp

cwebp-bin is listed as an optional dependency.
If you can't install it, install cwebp manually:

  • FreeBSD: pkg install graphics/webp
  • OS X: brew install webp
  • Ubuntu/Debian: sudo apt-get install webp

Usage

var Webp = require('broccoli-webp')

var outputNode = new Webp(inputNode, options)
  • inputNode: A node (tree) that contains the images you want to convert.
  • options: A hash of options. Currently supported:
    • quality (number, 0..100): compression quality for JPEGs (PNGs are converted to lossless WebP)
    • alphaQuality (number, 0..100): transparency quality
    • compression (number, 0 -- fast, 6 -- slowest): compression strength

Example

var Webp = require('broccoli-webp')

var img = 'img'

var webp = new Webp(img, {quality: 80})

return [img, webp]

Contributing

Please feel free to submit pull requests!

By participating in this project you agree to follow the Contributor Code of Conduct.

License

This is free and unencumbered software released into the public domain.
For more information, please refer to the UNLICENSE file or unlicense.org.

Keywords

FAQs

Package last updated on 04 Apr 2016

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