Tricky Tricks ›› Programming Tricks ›› CSS Tricks ›› Css Font Shorthand Rule

Css Font Shorthand Rule

CSS Tricks

CSS font shorthand rule:

When styling fonts with CSS you may be doing this:

 
 font-size: 1em;
line-height: 1.5em;
font-weight: bold;
font-style: italic;
font-variant: small-caps;
font-family: verdana,serif; There's no need though as you can use this CSS shorthand property: font: 1em/1.5em bold italic small-caps verdana,serif

Partners