Just when you think you’ve been all clever by putting zero width non joiner characters around em dashes, the Kindle renderer decides to get its knickers in a twist and does this:

ZWNJ bug on the Kindle

The markup that produced the third line of that image was this:

<p width="0">Same bug with <i>italic</i>&#x200c;,
<b>bold</b>&#x200c; or

Do you see repeated words in the markup? No, me neither. Putting a ZWNJ (U+200C) character straight after the end of another element will cause the final word of that element to be repeated.

In practice, this is easily avoided. If you don’t put a ZWNJ before an em dash where that em dash comes directly after some styled element (e.g. bold, italic or text size change), you won’t hit this bug and all you lose is one extra line-break point.

If you weren’t using any ZWNJ characters around em dashes, you’d have fewer line breaks anyway, so nothing is lost.

In practice, as I’ve said before, I put zero width spaces around em dashes, and only change those into zero width non joiners for the Kindle’s benefit, with a script. That script also searches for places where the ZWNJ will trigger the Kindle bug and removes them, so I don’t have to think about this bug when I’m marking up a text.