mixtur / webpack-spritesmith

Webpack plugin that converts set of images into a spritesheet and SASS/LESS/Stylus mixins
498 stars 56 forks source link

using retina '@2x' and padding, but only @1x image has padding #69

Closed jinghaonode closed 6 years ago

jinghaonode commented 6 years ago

new SpritesmithPlugin({ src: { cwd: path.resolve(dirname, '../src/ico'), glob: '*.png' }, target: { image: path.resolve(dirname, '../src/assets/sprite.png'), css: path.resolve(__dirname, '../src/assets/sprite.scss') }, apiOptions: { cssImageRef: '~@/assets/sprite.png' }, retina: '@2x', spritesmithOptions: { algorithm: 'top-down', padding: 20 }, }) 4165608

mixtur commented 6 years ago

should be fixed in 0.5.2