Package Exports
- gulp-sprite-generator
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (gulp-sprite-generator) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
gulp-sprite-generator
Generate sprites from stylesheets.
Plugin that generate sprites from your stylesheets (using spritesmith) and then updates image references.
Install
Install with npm
npm install --save-dev gulp-sprite-generator
Example
var gulp = require('gulp');
var changed = require('gulp-sprite-generator');
var SRC = 'src/*.css';
var DEST = 'dist';
gulp.task('default', function () {
gulp.src(SRC)
.pipe(changed(DEST))
// ngmin will only get the files that
// changed since the last time it was run
.pipe(ngmin())
.pipe(gulp.dest(DEST));
});
API
changed(dest, options)
dest
Type: String
The destination directory. Same as you put into gulp.dest()
.
This is needed to be able to compare the current files with the destination files.
options
Type: Object
Set options.extension
value to specify extension of the destination files.
gulp.task('jade', function() {
gulp.src('./src/**/*.jade')
.pipe(changed('./app/', { extension: '.html' }))
.pipe(jade())
.pipe(gulp.dest('./app/'))
});
License
MIT © Sindre Sorhus