Interface Position<TRoute>

A position of the match inside the route.

May represent a position after the end of the route.

Type Parameters

  • TRoute extends PathRoute

    A type of tested route.

Hierarchy

Properties

entry?: TRoute["path"][0]

The first entry of the match or undefined for the position after the route end.

entryIndex: number

The index of the first entry of the match.

Equals to path length for the position after the end of the route.

matcherIndex: number

The index of the matcher in the route pattern.

nameOffset: number

An offset of the first character within the first entry of the match.

pattern: RoutePattern<TRoute>

The route pattern the matcher belongs to.

route: TRoute

Target route.

Generated using TypeDoc