Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/path_to_regexp/index.ts

Turn a path string such as `/user/:name` into a regular expression
Go to Latest
import * as pathToRegexp from "https://deno.land/x/path_to_regexp@v8.0.0/index.ts";

Classes

Tokenized path instance.

Functions

Compile a string to a template function for the path.

Parse a string for the raw tokens.

Interfaces

A set of possible tokens to expand when matching.

A match result contains data about the path match.

A parameter designed to match arbitrary text within a segment.

Plain text.

A wildcard parameter designed to match multiple segments.

Type Aliases

Decode a string into another string.

Encode a string into another string.

A match is either false (no match) or a match result.

The match function takes a string and returns whether it matched the path.

A sequence of path match characters.