vendredi 24 juin 2016

Long words appear on new line rather using break-word to break the word


When writing articles I sometimes need to use long strings with no spaces and instead of the word breaking and wrapping, these words are being put in their own line. This leaves a big gap of whitespace in the preceeding sentence.

You can see an example of this here in the "How CryptoRoger Encrypts a Victim's Files" section:

http://www.bleepingcomputer.com/news/security/new-ransomware-called-cryptoroger-that-appends-crptrgr-to-encrypted-files/

I also added an example in this fiddle:

https://jsfiddle.net/s5u53vmq/

My CSS is currently set to the following so that words don't overflow the div and I was hoping break:

.articleBody p {
  word-wrap: break-word;
  overflow-wrap: break-word;
}

Is there anything else I should be using so that these long words break rather than moving to the next line?


Aucun commentaire:

Enregistrer un commentaire