@OSUBlake : i tried but loadash is not working with emojis, it split text in the same fashion as splitText (resulting in �). And even if it was splitting text without blowing up surrogates pairs I don't see the point of using it outside splittext...
@Jonathan : I know the difference between an <img> and a character... emojis can be both. And in both case splittext is failing :
First case : emoji is displayed as characters in a string, some emoji are encoded with 2 or 4 UTF8 characters and splitText doesn't care about that. so it split one emoji in 2 or 4 unknow characters : �
Second case : emoji is displayed as an <img> in the middle of an html string because in the first case emoji are not pretty : splitText doesn't work with <img> those tags are stripped.
Any way, it took me thirty minutes to modify SplitText.js to solve the first case and it's working perfectly now. I would have liked to share it but it's not open source so...
For the second case : why splitText cannot put <img> tags (or any kind of html tag by the way) into div like it do with characters?