Content with Style

Web Technique

Unitless line height in CSS

by Pascal Opitz on July 9 2007, 05:11

For a couple of years now I keep stressing the fact that line-height works best when you don’t provide a unit. And I am not saying this for no reason.

As neatly explained by Eric Meyer the unitless line height doesn’t enforce it’s computed size onto the inheriting element.