Skip to content

Commit

Permalink
Fix readme
Browse files Browse the repository at this point in the history
  • Loading branch information
1000ch committed May 25, 2018
1 parent 371b4a8 commit d28f57a
Showing 1 changed file with 15 additions and 11 deletions.
26 changes: 15 additions & 11 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ gulp.task('default', ['image']);
You can pass an object to `image()` as argument such as following:

```javascript
gulp.task('image', function () {
gulp.task('image', () => {
gulp.src('./fixtures/*')
.pipe(image({
pngquant: true,
Expand All @@ -63,16 +63,20 @@ Set `false` for optimizers which you don't want to apply. And you can set `concu
You can configure parameters applied to each optimizers such as following:

```javascript
options: {
optipng: ['-i 1', '-strip all', '-fix', '-o7', '-force'],
pngquant: ['--speed=1', '--force', 256],
zopflipng: ['-y', '--lossy_8bit', '--lossy_transparent'],
jpegRecompress: ['--strip', '--quality', 'medium', '--min', 40, '--max', 80],
mozjpeg: ['-optimize', '-progressive'],
guetzli: ['--quality', 85],
gifsicle: ['--optimize'],
svgo: ['--enable', 'cleanupIDs', '--disable', 'convertColors']
}
gulp.task('image', () => {
gulp.src('./fixtures/*')
.pipe(image({
optipng: ['-i 1', '-strip all', '-fix', '-o7', '-force'],
pngquant: ['--speed=1', '--force', 256],
zopflipng: ['-y', '--lossy_8bit', '--lossy_transparent'],
jpegRecompress: ['--strip', '--quality', 'medium', '--min', 40, '--max', 80],
mozjpeg: ['-optimize', '-progressive'],
guetzli: ['--quality', 85],
gifsicle: ['--optimize'],
svgo: ['--enable', 'cleanupIDs', '--disable', 'convertColors']
}))
.pipe(gulp.dest('./dest'));
});
```

## License
Expand Down

0 comments on commit d28f57a

Please sign in to comment.