ParsedHost

utils · /index·interface

Structured breakdown of a host header.

Properties

app
Dev app segment (``storefront``, ``admin``, ``landing``, …) when present.
hostname
Fully normalized hostname (lowercased, port-stripped, no trailing dot).
isDev
boolean
True when the hostname lives on a development TLD.
port
number
Port if present and valid, else null.
segments
readonly string[]
Raw segment list, useful for callers that want to walk the labels.

AppName BuildEnv DevTld Hostname ShopHandle appFromHost isDevelopment isDevHost

Sourcehostname.ts:164Edit the JSDoc directly
Metadata@nordcom/commerce-utils@0.0.0Open in GitHub ↗

On this page