gulp-lazy-minify
This plugin is used to minify JS/CSS only when it's needed.
There are currently 2 conditions where minifying is not needed:
- The source file is already minified
- There exists a minified version of the source file in the same directory
Usage
var gulp = ;var lazyMinify = ; gulp;
Assumptions:
- A JS file is a file with extension .js
- A CSS file is a file with extension .css
- A minified file is a file where it has .min before the extension
JS minification uses gulp-uglify
CSS minififcation uses gulp-minify-css