Skip to main content

InitRootChaynsHistoryLayerOptions

Index

Properties

Properties

optionalsegmentCount

segmentCount?: number

Number of URL path segments the root layer owns. When provided, segments are resolved from the URL immediately at construction so that getRoute() is populated on the very first render.

optionalurl

url?: string

The current page URL used to seed initial route segments.

  • Browser: defaults to window.location.pathname — no need to set this.
  • SSR: pass the request URL (e.g. req.url or router.asPath) so child layers receive the correct initial segments on the server.
Page Options