Convert directory with images to dataUri stylesheet
JavaScript
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
test
.gitignore
LICENSE
README.md
index.js
package.json

README.md

gulp-baseimg

Gulp plugin for generate data uri stylesheet from set of images.

##Usage

npm install gulp-baseimg --save-dev

###Example config

gulp.task('imgBase', function() {
    gulp.src('./images/data/*.png')
        .pipe(baseimg({
            styleTemplate: 'scss/data_gen.scss.mustache',
            styleName: '_data_gen.scss'
        }))
        .pipe(gulp.dest('./scss'));
});

###Options

####styleTemplate Path to mustache template

####styleName Result file name

###Template variables ####items Array of images data

####items[i].name Image filename without extension

####items[i].width & items[i].height Image width and height in pixels

####items[i].data Data URI string