Skip to content

Instantly share code, notes, and snippets.

@owzim
Created January 8, 2015 12:41
Show Gist options
  • Save owzim/92d3df43128eda7c0c93 to your computer and use it in GitHub Desktop.
Save owzim/92d3df43128eda7c0c93 to your computer and use it in GitHub Desktop.

Revisions

  1. Christian Raunitschka created this gist Jan 8, 2015.
    13 changes: 13 additions & 0 deletions fix-ie8-icon-font.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,13 @@
    (function() {
    // icon font rendering fix
    // see: http://stackoverflow.com/a/10557782/426890
    var head = document.getElementsByTagName('head')[0],
    style = document.createElement('style');
    style.type = 'text/css';
    style.styleSheet.cssText = ':before,:after{content:none !important';
    head.appendChild(style);
    setTimeout(function(){
    head.removeChild(style);
    }, 0);
    })();