Skip to content

Instantly share code, notes, and snippets.

@viclm
Created May 7, 2018 08:23
Show Gist options
  • Save viclm/da20b4c911a04a5c57ffce8229a75ff9 to your computer and use it in GitHub Desktop.
Save viclm/da20b4c911a04a5c57ffce8229a75ff9 to your computer and use it in GitHub Desktop.
font-face(filename)
@font-face
font-family basename(filename)
src url(filename + '.woff') format('woff')
font-weight normal
font-style normal
[data-icon]::before
/* use !important to prevent issues with browser extensions that change fonts */
font-family basename(filename) !important
[data-icon]::before
content attr(data-icon)
speak none
font-style normal
font-weight normal
font-variant normal
text-transform none
line-height 1
/* Enable Ligatures ================ */
letter-spacing 0
-webkit-font-feature-settings "liga"
font-feature-settings "liga"
-webkit-font-variant-ligatures discretionary-ligatures
font-variant-ligatures discretionary-ligatures
/* Better Font Rendering =========== */
-webkit-font-smoothing antialiased
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment