0.0.2 • Published 7 years ago

sprite-plugin-webpack v0.0.2

Weekly downloads
5
License
MIT
Repository
github
Last release
7 years ago

TO DO.

An Example:

const SpritePlugin = require('sprite-plugin-webpack');

new SpritePlugin({
	src: './src/asset/sprite',// dir of sprite slices
	dest: {
		image: './src/images/sprite_[group][dpr].png',// paths of generated image files. required.
		css: './src/css/_sprite_[group].scss'// paths of generated css files. required.
	},
	watch: {
		pattern: 'src/asset/sprite/**/*.{jpg,png}',// watch these files to reload. required.
		cwd: undefined// current working dir for watching. optional.
	},
	useRetina: false,// optional. default: false
	useRem: false,// optional. default: false
	cssTemplate: function(sprite, options) {}// the function to generate css contents. optional.
})