Description
SVG for Everybody is a small script that lets browsers use external SVG spritemaps, adding external content support where a browser lacks it. The README says Chrome, Safari 7.1 and later, Firefox, Edge 13 and later, and Opera already handle spritemaps, and the script polyfills the experience in Safari 6, IE 6 and later, and Edge 12. To use it, you include the script in your document. For Internet Explorer 6 to 8, the README asks you to include a legacy script instead, and to place the script in the head so the HTML5 elements are shimmed. As of version 2.0.0 you must call svg4everybody() manually, and if you use an AMD or CommonJS loader you can call it inside the callback. For the best results in IE, the README recommends setting the X-UA-Compatible header to ie=edge. Browsers without SVG support fall back to images, and by default the fallback is a PNG file in the same location as the SVG. The project is public on GitHub under the jonathantneal account and is published on npm.…
Highlights
- Use external SVG spritemaps in any browser
- Polyfill for Safari 6, IE 6 and later, and Edge 12
- Legacy script for IE 6 to 8
- PNG fallback for browsers without SVG
- Manual svg4everybody() call since v2.0.0
Ratings & Reviews
No ratings yet
Be the first to rate svg4everybody.
People also visit
svg4everybody FAQ
What does SVG for Everybody do?
It lets browsers use external SVG spritemaps, adding external content support where it is missing.
Which browsers already support it natively?
The README lists Chrome, Safari 7.1 and later, Firefox, Edge 13 and later, and Opera.
Do I have to call anything in code?
Yes. As of version 2.0.0 you must call svg4everybody() manually.
What about old Internet Explorer?
For IE 6 to 8 include the legacy script instead, and set X-UA-Compatible to ie=edge for the best results.
Is it open source?
Yes. The source is public on GitHub.
What are the best svg4everybody alternatives?
Popular alternatives to svg4everybody include svg-sprite, @svgmoji/noto and svg2sprite. See all svg4everybody alternatives















