Node.js examples for String:Case
Convert String to Hiragana Case
String.prototype.toHiraganaCase = function() { var c, i = this.length, a = []; while(i--)/*from w w w. ja v a 2 s . c om*/ { c = this.charCodeAt(i); a[i] = (0x30A1 <= c && c <= 0x30F6) ? c - 0x0060 : c; }; return String.fromCharCode.apply(null, a); };