dimanche 19 avril 2015

JavaScript Regex for capitalized letters with accents

In JavaScript, its easy to match letters and accents with this regex:



text.match(/[a-z\u00E0-\u00FC]+/i);


And only the lowercase letters and accents without the i option:



text.match(/[a-z\u00E0-\u00FC]+/);


But what is the correct regular expression to match only capitalized letters and accents?


Aucun commentaire:

Enregistrer un commentaire