DEV Community

Cover image for @font-face Rule
Amjad Kamboh
Amjad Kamboh

Posted on

@font-face Rule

With the @font-face rule, web designers do not have to use one of the "web-safe" fonts anymore.
In the @font-face rule you must first define a name for the font (e.g. myFont), and then point to the font file.

@font-face {
font-family: myFont;
src: url(sansation_light.woff);
}

div {
font-family: myFont;
}

font-face

Top comments (0)