10000 GitHub - paulpflug/imagemin-manager: declarative use of imagemin \o/
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

paulpflug/imagemin-manager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

imagemin-manager

declarative use of imagemin \o/.

Features:

  • image processing powered by imagemin
  • image preprocessing powered by jimp
  • will skip files, when the source and the config file are older then the target

Install

npm install --save-dev imagemin-manager

Usage

// imagemin.config.js
module.exports = { 
  from: ["resources"],
  to: "deploy/resources",
  process: {
    ico: "copy", // will match files with /.ico$/
    jpg: require("imagemin-guetzli")({quality: 87})
  }
  preprocess: {// see jimp for available commands
    jpg: [
      ["resize","AUTO",400]
    ]
  }
}
# call in terminal:
imagemin-manager
// or use a task in your package.json
...
  "scripts": {
    ...
    "deploy:imagemin": "imagemin-manager"
    ...
  }
...

License

Copyright (c) 2017 Paul Pflugradt Licensed under the MIT license.

About

declarative use of imagemin \o/

Resources

Stars

Watchers

Forks

Packages

No packages published
0