Answers for "check if word has accented or unaccented javascript"

5

javascript remove diacritics

//Normalize diacritics characters from originalText
var originalText = "éàçèñ"
var result = originalText.normalize('NFD').replace(/[\u0300-\u036f]/g, "")
console.log(result)
Posted by: Guest on June-14-2020
2

remove accesnt and simbols and paranthesis from text js

var originalText = "éàçèñ"
var result = originalText.normalize('NFD').replace(/[\u0300-\u036f]/g, "")
console.log(result)
Posted by: Guest on June-14-2020
0

check if word has accented or unaccented javascript

var accentArray = ["á","à","ã","â","é","è","ê","í","ì","î","õ","ó","ò","ô","ú","ù","û"]
var stringToCheck = "áeiou"

for(var i=0; i < stringToCheck.length; i++){
    for(var j=0; j < accentArray.length; j++){
        if(stringToCheck[i] === accentArray[j]){
            alert("String has accents!");
        }
    }
}
Posted by: Guest on June-25-2020

Code answers related to "check if word has accented or unaccented javascript"

Code answers related to "Javascript"

Browse Popular Code Answers by Language