ACBlue
ACBlue

Reputation: 103

Javascript includes behavior for non ASCII text based on browser (Mozilla Vs Chrome)

I am writing a simple app where text comes in, certain words are to be replaced and the text is sent out again. It all works well as long as I am working with ASCII characters.

I now want to do the same for Indic text. I was initially using str.replace() and found out that it was not replacing anything. I then checked if str.includes() works. It turns out that str.includes("नमन") works (returns true) on Firefox but not on Chrome. I find this very strange. Can someone point out if I am missing any settings?

Upvotes: 0

Views: 42

Answers (0)

Related Questions