Import
import { parseWithRest } from "@typed/router/Path";Signatures
export declare function parseWithRest(input: string): RuntimeParseResult;Why
The runtime grammar can be embedded while preserving where parsing stopped.
Ownership and lifetime
parseWithRest parses immediately and returns fresh AST array state; it retains neither the input string nor parser cursor.
Examples
import { parseWithRest } from "@typed/router/Path"
const [ast, rest] = parseWithRest("/users/:id?tab=:tab? trailing")