Description
svg-sprite is a low-level Node.js module that takes a set of SVG files, optimises them and combines them into SVG sprites of several types, along with matching stylesheet resources in formats such as CSS, Sass, LESS and Stylus. The README describes a traditional CSS sprite, in which icons are placed in one file and selected by their position, and stacks, in which each icon is a separate symbol that can be referenced by id. The module is designed to sit inside a build process, and the README includes sections on using it with task runners such as Grunt and Gulp, and on the usage pattern for generating sprites. Because it is low-level, you pass it the files and choose the output, which gives you control over the result. The project is on GitHub under the svg-sprite organisation, with build and coverage checks. It suits front-end developers who want to ship a set of icons efficiently, with one request for many icons.…
Highlights
- Optimises SVG files and bakes sprites
- Traditional CSS sprites and SVG stacks
- CSS, Sass, LESS and Stylus resources
- Works with Grunt and Gulp
Ratings & Reviews
No ratings yet
Be the first to rate svg-sprite.
People also visit
Tiny SVG
Web application for optimizing SVG files and generating framework-specific code
svg-sprite FAQ
What does svg-sprite do?
It optimises SVG files and combines them into sprites, with stylesheet resources for CSS, Sass, LESS or Stylus.
What is a stack?
The README describes stacks as sprites in which each icon is a separate symbol referenced by id.
How does it fit a build?
It is a Node.js module that can be used with Grunt, Gulp and similar task runners.
Where is the code?
On GitHub under the svg-sprite organisation.
What are the best svg-sprite alternatives?
Popular alternatives to svg-sprite include svg2sprite, @svgmoji/noto and astro-iconset. See all svg-sprite alternatives















