Support for hyphen linebreak formatting in HTML!

By | November 29, 2012
This is very nice… now missing ancient IE versions, and Chrome, before all major browsers are covered. It should make formatting – especially of small divs, like Postits or multi-column layouts, or dynamic layouts – a lot nicer for web developers!

Reshared post from +John A Hardy

Hyphenation now works in Firefox and Safari.

This is what +Tim Bray should have used instead of relying upon crappy Javascript to do his typography.

So put this rule into your CSS now

p {
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
-o-hyphens: auto;
hyphens: auto;

You also need to declare

<html lang="en">

Embedded Link

Hyphenation works! – QuirksBlog
Yesterday I found that proper hyphenation of text is now supported by Firefox, IE10, and Safari. So I added it to my main style sheet and it should work in these browsers across my site. I also advise…

Leave a Reply

Your email address will not be published.