
Delivering Octicons with SVG - jasoncartwright
https://github.com/blog/2112-delivering-octicons-with-svg
======
robrichard
Does this cause the HTML sent over the wire to be bloated, i.e. the svg for
the same icon could be repeated multiple times on the same page?

~~~
fullsailor
I expect that gzip would make the over the wire price for repeated icons
insignificant.

~~~
venning
Yes and no.

The repetitions would have to appear within 32KB of each other to be captured
in the DEFLATE window [1] which, given that a lot of pages can be 100s of KBs
of _uncompressed_ text, may make that impossible.

Additionally, the zlib (or whatever) compression settings would have to be set
aggressively enough to identify those duplicates as the best run-lengths to
encode. Since GitHub is generating a lot of this live and delivering with low
TTFB, they may be using a less aggressive than necessary setting.

[1]
[https://en.wikipedia.org/wiki/DEFLATE#Duplicate_string_elimi...](https://en.wikipedia.org/wiki/DEFLATE#Duplicate_string_elimination)

------
mchahn
We Atom community developers have used a lot of Octicons due to the github
heritage. I hope the Atom developers provide some easy conversion utility like
github used internally.

------
msoad
Icon fonts are awful. I'm glad GitHub made this change.

I see a bug in repository page:
[http://i.imgur.com/GdyeFXK.png](http://i.imgur.com/GdyeFXK.png)

------
nailer
> We can animate them

> We’re not saying we should, but we could, though SVG animation does have
> some practical applications—preloader animations, for example.

FYI SVG animation is deprecated in Chrome 45 and later. You'll want to use CSS
animation instead.

See [https://developer.mozilla.org/en-
US/docs/Web/SVG/SVG_animati...](https://developer.mozilla.org/en-
US/docs/Web/SVG/SVG_animation_with_SMIL)

Main thing is now you can't animate SVG in 'before' or 'after' pseudoelements.

------
alex_doom
Curious if they have any fallback for the very few browsers that can't render
inline svg.

~~~
brotherjerky
SVG support is nearly universal now:
[http://caniuse.com/#feat=svg](http://caniuse.com/#feat=svg) \-- plus, the
icons aren't necessary for the UI to function, so perhaps they've forgone the
fallback.

~~~
J_Darnley
I wonder, do more people use an old browser or disable web fonts? <IE8 could
be a lot of people.

~~~
youngtaff
My content blocker disables them on my iPad

------
swiley
Icons kind of suck when you can just use text which is smaller and more
descriptive. This is definitely an improvement over using webfonts for custom
icons though.

