1.0.8 • Published 4 years ago

image_opt v1.0.8

Weekly downloads
-
License
ISC
Repository
-
Last release
4 years ago

image_opt

image_opt based of the plugin imagemin

Install

$ npm i image_opt

Usage

const image_opt = require('image_opt')

image_opt.convert();
image_opt.compress();

API

image_opt(options)(buffer)

Returns a Promise<Buffer>.

methods

compress

Type: void

const compress: () => void compresses .svg, .jpeg and .png files with a given project.

convert

Type: void

const convert: () => void converts all .jpeg and .png files found within a project to next generation image format .webp format.

buffer

Type: buffer

Buffer to optimize.

License

MIT © Imagemin