imagemin-svgo
SVGO imagemin plugin

imagemin-svgo downloads imagemin-svgo version imagemin-svgo license

imagemin-svgoSimilar Packages:
Npm Package Weekly Downloads Trend
3 Years
🌟 Show real-time usage chart on imagemin-svgo's README.md, just copy the code below.
## Usage Trend
[![Usage Trend of imagemin-svgo](https://npm-compare.com/img/npm-trend/THREE_YEARS/imagemin-svgo.png)](https://npm-compare.com/imagemin-svgo#timeRange=THREE_YEARS)
Cumulative GitHub Star Trend
🌟 Show GitHub stars trend chart on imagemin-svgo's README.md, just copy the code below.
## GitHub Stars Trend
[![GitHub Stars Trend of imagemin-svgo](https://npm-compare.com/img/github-trend/imagemin-svgo.png)](https://npm-compare.com/imagemin-svgo)
Stat Detail
Package
Downloads
Stars
Size
Issues
Publish
License
imagemin-svgo589,7231292.91 kB3a year agoMIT
README for imagemin-svgo

imagemin-svgo GitHub Actions Status

SVGO imagemin plugin

Install

npm install imagemin-svgo

Usage

import imagemin from 'imagemin';
import imageminSvgo from 'imagemin-svgo';

await imagemin(['images/*.svg'], {
	destination: 'build/images',
	plugins: [
		imageminSvgo({
			plugins: [{
				name: 'removeViewBox',
				active: false
			}]
		})
	]
});

console.log('Images optimized');

API

imageminSvgo(options?)(buffer)

Returns a Promise<Buffer>.

options

Type: object

Pass options to SVGO.

buffer

Type: Buffer

The buffer to optimize.