3 ms·
Managing a sprite for even 10 different icons is a huge pain in the ass. Let's say you need a light and dark version of each icon, that makes it 20 different i
by dntrkv 13y ago
Managing a sprite for even 10 different icons is a huge pain in the ass.
Let's say you need a light and dark version of each icon, that makes it 20 different icons. Then you want a small version, and a big version of each, that brings it to 40. Then you need a version of each for retina, those 10 icons are now 80.
A font icon library is a god send when dealing with all these different variations since you can make these changes in the CSS without updating any of the icon sources files.
- tshadwell 13y agoUse an icon font generated by icomoon or the like. That does not require Javascript, HTML and CSS prerequisites, is only as heavy as the used constituent SVG elements and is well-supported.
- dntrkv 13y agoI do use icomoon, it's an amazing tool. I was just replying to the parents comment about how necessary these abstractions are: "How many icons will a website need before an abstraction like this is necessary to manage them?" I say they are very necessary.