Skip to content

Instantly share code, notes, and snippets.

@inriverie
Created January 25, 2015 06:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save inriverie/0347cb2513ad7f4be0ff to your computer and use it in GitHub Desktop.
Save inriverie/0347cb2513ad7f4be0ff to your computer and use it in GitHub Desktop.
@font-face Style Linking
/*
Example of Style Linking fonts using a single font-family name.
DataURI `src` is url('data:font/woff2;base64,...') format('woff2'), url('data:font/woff;base64,...') format('woff');
*/
@font-face {
font-family:'myfont';
src: url('myfont.woff2'), url(myfont.woff);
font-style: normal;
font-weight:400;
}
@font-face {
font-family:'myfont';
src: url('myfont-boldItalic.woff2'), url(myfont-boldItalic.woff);
font-style: italic;
font-weight:700;
}
/*
When setting the font-family property on a selector, font-style and font-weight need to be defined.
*/
.pullquote{
font-family:'myfont', sans-serif;
font-style:italic;
font-weight:700;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment