variable / @typed/router/AST

slash

Constructs a root slash Path AST node.

Package version
1.0.0-beta.13
Category
Path syntax
Since
1.0.0

Import

import { slash } from "@typed/router/AST";

Signatures

export declare const slash: () => PathAst.Slash;

Why

Root syntax is represented without an empty or nullable sentinel.

Ownership and lifetime

slash returns a fresh plain AST node immediately and retains any supplied child nodes or arrays by reference; it acquires no external resource.

Source