Skip to main content
zerotal

Documentation


Documentation / @zerotal/core / index / CompiledDomain

Interface: CompiledDomain

Defined in: router/domain.ts:9

Host-aware routing support for Router.group({ domain }).

A domain pattern like :tenant.app.com is compiled into a matcher that both tests a request's host and extracts the dynamic labels as subdomain params, exposed on the request via ctx.subdomains.

Properties

source

source: string

Defined in: router/domain.ts:11

The original pattern, e.g. ':tenant.app.com'.


regex

regex: RegExp

Defined in: router/domain.ts:12


params

params: string[]

Defined in: router/domain.ts:14

Param names in order, e.g. ['tenant'].