Skip to content
This repository has been archived by the owner on May 8, 2024. It is now read-only.

Latest commit

 

History

History
56 lines (31 loc) · 916 Bytes

readme.md

File metadata and controls

56 lines (31 loc) · 916 Bytes

imagemin-jpegtran Build Status

jpegtran imagemin plugin

Install

$ npm install --save imagemin-jpegtran

Usage

const imagemin = require('imagemin');
const imageminJpegtran = require('imagemin-jpegtran');

imagemin(['images/*.jpg'], 'build/images', {use: [imageminJpegtran()]}).then(() => {
	console.log('Images optimized');
});

API

imageminJpegtran([options])(buffer)

Returns a promise for a buffer.

options

progressive

Type: boolean
Default: false

Lossless conversion to progressive.

arithmetic

Type: boolean
Default: false

Use arithmetic coding.

buffer

Type: buffer

Buffer to optimize.

License

MIT © imagemin