DEV Community

Discussion on: Quick and easy way of counting UTF-8 characters in Javascript

tbroyer profile image
Thomas Broyer

That's a good reminder, which holds true for other languages / runtimes as well (I know at least Java/JVM that works the same, maybe also .NET, can't remember).

I don't get why you're talking about UTF-8 here though. It's Unicode vs UCS-2.

coolgoose profile image
Alexandru Bucur Author

Hi Thomas,

The title is missleading I agree (hence linking to the UCS-2 explanation).
Unfortunately when encountered with unicode, nobody really searches for UCS-2 javascript unicode handling.