javascript - Why do web sites replace unicode chars with images? -


recently installed noscript plugin in firefox control execution of javascript. noticed websites use fancy unicode charaters place holders images, replaced images once allow javascript. 1 example site github.com, see screenshot taken before enabled javascript.

what's advantage of instead of place image directly in html or css?

screenshot of github repo fancy unicode chars highlighted. censored stuff because not repo...

the sites using icon font (or more one).

an icon font regular font file contains images. it's technique cut down on http requests , enable other features.

now, how or why that's defeated noscript plugin, don't know. (edit — it's apparently configurable noscript option, selected default. @font-face rules blocked, ostensibly security reasons.)

in github sample, quick trip developer tools shows there's font called "octicons".


Comments

Popular posts from this blog

css - SVG using textPath a symbol not rendering in Firefox -

Java 8 + Maven Javadoc plugin: Error fetching URL -

datatable - Matlab struct computations -