{"library":"rollup-plugin-sprite","title":"rollup-plugin-sprite","description":"A Rollup plugin that generates a sprite sheet from a set of images using spritesmith and outputs corresponding SASS/LESS/Stylus/CSS mixins. Current stable version: 0.1.2. Infrequently updated; last commit 2019. Differentiates by integrating sprite generation into the Rollup build pipeline, automating the creation of CSS sprites and mixins directly from source images. Compared to standalone tools like grunt-sprite or gulp.spritesmith, this plugin offers seamless bundling with Rollup, reducing build configuration overhead.","language":"javascript","status":"maintenance","last_verified":"Mon Apr 27","install":{"commands":["npm install rollup-plugin-sprite"],"cli":null},"imports":["import spritesmith from 'rollup-plugin-sprite'","import { spritesmith } from 'rollup-plugin-sprite'","import type { SpritePlugin } from 'rollup-plugin-sprite'"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import spritesmith from 'rollup-plugin-sprite';\nimport { defineConfig } from 'rollup';\n\nexport default defineConfig({\n  input: 'src/main.js',\n  output: {\n    dir: 'dist',\n    format: 'cjs'\n  },\n  plugins: [\n    spritesmith({\n      src: {\n        cwd: 'src/ui/images/sprite',\n        glob: '**/*.png'\n      },\n      target: {\n        image: 'src/ui/images/sprite.png',\n        css: 'src/ui/sass/sprite.scss'\n      },\n      cssImageRef: '../images/sprite.png',\n      output: {\n        image: 'dist/images/sprite.png'\n      },\n      spritesmithOptions: {\n        padding: 5\n      }\n    })\n  ]\n});","lang":"javascript","description":"Demonstrates basic plugin configuration: source glob, target image and CSS paths, output directory, and spritesmith options.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}