CSS text-decoration Property
The text-decoration property defines the decoration added to or removed from text using the element's colour.
Possible Values
- none - no text decoration is added - the initial value.
- underline - text is underlined.
- overline - a line is displayed above text.
- line-through - a line is placed through the middle of the text.
- blink - text is supposed to "blink" or alternate between visible and hidden.
- inherit - inherited from the parent element.
Examples of the text-decoration property in action:
- {text-decoration: underline} A line is displayed underneath text.
- {text-decoration: overline} A line is displayed above text.
- {text-decoration: line-through} Text has a strike through the middle.
- {text-decoration: blink} This text should "blink"
NOTE: Internet Explorer, Chrome and Safari do not support the blink value, but this is not neccessarily
a bad thing as 'blinking' text can cause accessibility problems relating to screen readers or users with epilepsy.
Web designers should also think long and hard before using the underline value of this property as most internet users expect underlined text to
be a hyperlink and confusing that expectation will quite possibly have a negative effect on user experience and website usability.
