Skip to content

Instantly share code, notes, and snippets.

@argyleink
Last active December 12, 2017 18:28
Show Gist options
  • Save argyleink/5463021 to your computer and use it in GitHub Desktop.
Save argyleink/5463021 to your computer and use it in GitHub Desktop.
Cross browser word-break, so long urls and "wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww" don't outgrow your containers.
.word-break {
-ms-word-break: break-all;
word-break: break-word;
word-wrap: break-word;
-webkit-hyphens: auto;
-moz-hyphens: auto;
hyphens: auto;
}
@DarkFisk
Copy link

line -ms-word-break: break-all; breaks each char of a word in IE11

@tomexx
Copy link

tomexx commented Nov 27, 2017

doesn't work in Firefox

@MuthaheerKhan
Copy link

doesn't work in chrome

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment