Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Javascript Normalize - Removes Accents And Others Invalid Chars.

DZone's Guide to

Javascript Normalize - Removes Accents And Others Invalid Chars.

·
Free Resource
// this snippet is useful for making urls slugs, or comparing user inputs to a normalized string.


    var normalize = (function() {
        var from = "ÃÀÁÄÂÈÉËÊÌÍÏÎÒÓÖÔÙÚÜÛãàáäâèéëêìíïîòóöôùúüûÑñÇç", 
            to   = "AAAAAEEEEIIIIOOOOUUUUaaaaaeeeeiiiioooouuuunncc",
            mapping = {};
        
        for(var i=0; i
  
Topics:

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}