svg-uri - SVG data uri for inlining small SVG icons in CSS

  •        10

Output a data uri, transparently compressing with svgo when installed. For those times when you only need a few small SVGS and want to inline them in your CSS.



Related Projects

svgo - :tiger: Node.js tool for optimizing SVG files

  •    Javascript

SVG Optimizer is a Nodejs-based tool for optimizing SVG vector graphics files. SVG files, especially those exported from various editors, usually contain a lot of redundant and useless information. This can include editor metadata, comments, hidden elements, default or non-optimal values and other stuff that can be safely removed or converted without affecting the SVG rendering result.

gulp-svgmin - Minify SVG files with gulp.

  •    Javascript

Minify SVG with SVGO. If you have any difficulties with the output of this plugin, please use the SVGO tracker.

SVG-NOW - SVG Optimizer for Adobe Illustrator

  •    Javascript

SVG NOW is an alternative SVG exporter for Adobe Illustrator currently under development. It is aimed at optimizing SVG files by post-processing the generated SVG code using SVGO. Creative Cloud members can install a beta version of this panel from the creative cloud add-ons website. It is free, open source (under MIT license) and will always be.

csstree - A tool set for working with CSS including fast detailed parser, walker, generator and lexer based on W3C specs and browser implementations

  •    Javascript

CSSTree is a tool set to work with CSS, including fast detailed parser (string->AST), walker (AST traversal), generator (AST->string) and lexer (validation and matching) based on knowledge of spec and browser implementations. The main goal is to be efficient and W3C spec compliant, with focus on CSS analyzing and source-to-source transforming tasks. NOTE: The project is in alpha stage since some parts need further improvements, AST format and API are subjects to change. However it's stable enough and used by packages like CSSO (CSS minifier) and SVGO (SVG optimizer) in production.

gulp-svg-sprite - SVG sprites & stacks galore — Gulp plugin wrapping around svg-sprite that reads in a bunch of SVG files, optimizes them and creates SVG sprites and CSS resources in various flavours

  •    Javascript

This document covers only gulp specific installation and configuration aspects. For a full list of features and options, please see the svg-sprite manual. NOTICE: By default, svg-sprite doesn't send any files downstream unless you configure it. There are tons of options available — please see below for some basic examples. Also, you should possibly take care of errors that might occur.

postcss-write-svg - Write SVGs directly in CSS

  •    Javascript

Write SVG lets you write SVGs directly in CSS. @svg at-rules generate SVG elements available to CSS. Within an @svg, descendant at-rules (like @rect) are interpreted as elements, while declarations (like width) are interpreted as attributes.

SVGInjector - Fast, caching, dynamic inline SVG DOM injection library

  •    Javascript

A fast, caching, dynamic inline SVG DOM injection library. Developed by Waybury for use in iconic.js, part of the Iconic icon system. There are a number of ways to use SVG on a page (object, embed, iframe, img, CSS background-image) but to unlock the full potential of SVG, including full element-level CSS styling and evaluation of embedded JavaScript, the full SVG markup must be included directly in the DOM.

svg-sprite - SVG sprites & stacks galore — A low-level Node

  •    Javascript

It comes with a set of Mustache templates for creating stylesheets in good ol' CSS or one of the major pre-processor formats (Sass, Less and Stylus). Tweaking the templates or even adding your own custom output format is really easy, just as switching on the generation of an HTML example document along with your sprite. For an up-to-date list of browsers supporting SVG in general respectively SVG fragment identifiers in particular (required for <defs> and <symbol> sprites as well as SVG stacks) please refer to

patternfills - A collection of svg patterns and build scripts that allow utilizing them in svg, css and d3

  •    HTML

This is a collection of svg-based pattern fills that can be used both as SVG patterns defs and CSS background image urls. There is also an example of how one might use pattern fills with d3.js. A lot of these pattens started from: which is an amazing project.

svgo - Go Language Library for SVG generation

  •    Go

The library generates SVG as defined by the Scalable Vector Graphics 1.1 Specification ( Output goes to the specified io.Writer.

inline_svg - Embed SVG documents in your Rails views and style them with CSS

  •    Ruby

Styling a SVG document with CSS for use on the web is most reliably achieved by adding classes to the document and embedding it inline in the HTML. This gem adds a Rails helper method (inline_svg) that reads an SVG document (via Sprockets, so works with the Rails Asset Pipeline), applies a CSS class attribute to the root of the document and then embeds it into a view.

postcss-inline-svg - PostCSS plugin to reference an SVG file and control its attributes with CSS syntax

  •    Javascript

PostCSS plugin to reference an SVG file and control its attributes with CSS syntax. See PostCSS docs for examples for your environment.

progress-bar-animation - Making a Doughnut Progress Bar - research notes

  •    Javascript

Looking through the different CSS pie chart implementations I decided that CSS is not fitted for the job. All solutions were hacks that would be hard to control. I was also worried that it will be cumbersome to make it work on all the browsers that we support. Canvas, with almost universal support, seemed more appealing. However, canvas would require me to implement timing (e.g. easing functions) and scaling (to support higher dpis) myself. Besides, I though that it would not utilize GPU as well as CSS transitions/transforms. SVG seemed like the best of both worlds: it's universally supported, doesn't need any hacks to create a required shape, utilizes CSS transitions to create animations and fits all screen dpis out of the box. So, I dusted off my SVG knowledge and started coding. Happy with the result, I sprinkled it with some CSS magic and made a short video showing it in action.

flag-icon-css - :flags: A collection of all country flags in SVG — plus the CSS for easier integration

  •    HTML

A collection of all country flags in SVG — plus the CSS for easier integration. See the demo. Which means that the flag is just going to appear in the middle of an element, so you will have to set manually the correct size of 4 by 3 ratio or if it's squared add also the flag-icon-squared class.

grunticon - A mystical CSS icon solution.

  •    HTML

grunticon is a Grunt.js task that makes it easy to manage icons and background images for all devices, preferring HD (retina) SVG icons but also provides fallback support for standard definition browsers, and old browsers alike. From a CSS perspective, it's easy to use, as it generates a class referencing each icon, and doesn't use CSS sprites. grunticon takes a folder of SVG/PNG files (typically, icons that you've drawn in an application like Adobe Illustrator), and outputs them to CSS in 3 formats: svg data urls, png data urls, and a third fallback CSS file with references to regular png images, which are also automatically generated and placed in a folder.

vivus - JavaScript library to make drawing animation on SVG

  •    Javascript

Vivus is a lightweight JavaScript class (with no dependencies) that allows you to animate SVGs, giving them the appearance of being drawn. There are a variety of different animations available, as well as the option to create a custom script to draw your SVG in whatever way you like. Try Vivus with your SVG on Vivus Instant. If you plan to use the library to animate a single SVG without callback or controls, this will allow you to download your animated SVG, powered by CSS, JavaScript free.