is_punnycode_domain
No overview available.
def is_punnycode_domain(
domain: string
) - > boolean
Determines if a domain name contains Punycode-encoded labels by checking for the 'xn--' prefix. Use this to identify Internationalized Domain Names (IDNs) that require decoding for human-readable display.
Parameters
| Name | Type | Description |
|---|---|---|
| domain | string | The fully qualified domain name or domain segment to be inspected for Punycode encoding |
Returns
| Type | Description |
|---|---|
boolean | True if the domain contains at least one Punycode-encoded segment, False otherwise |