• domain {string}

    The punycode.toUnicode() method converts a string representing a domain name containing [Punycode][] encoded characters into Unicode. Only the [Punycode][] encoded parts of the domain name are be converted.

    1. // decode domain names
    2. punycode.toUnicode('xn--maana-pta.com'); // 'mañana.com'
    3. punycode.toUnicode('xn----dqo34k.com'); // '☃-⌘.com'
    4. punycode.toUnicode('example.com'); // 'example.com'