live · mainnetoc · docs
specs · api · guides
docs / documentation

@orangecheck/vault-core


@orangecheck/vault-core / registrableDomain

Function: registrableDomain()

function registrableDomain(host: string): string;

Defined in: vault-core/src/origin.ts:46

The registrable domain (eTLD+1) of a hostname — mail.example.co.ukexample.co.uk. Falls back to the full host when the suffix is unknown (stricter, never looser).

Parameters

ParameterType
hoststring

Returns

string