Skip to content

Commit 67050d1

Browse files
committed
remove "matcher" api
1 parent f0c69a0 commit 67050d1

File tree

1 file changed

+4
-13
lines changed

1 file changed

+4
-13
lines changed

packages/route-pattern/README.md

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -60,27 +60,18 @@ pattern.match('https://remix.run/assets/styles/main.css');
6060

6161
```ts
6262
class RoutePattern {
63+
readonly source: string;
6364
constructor(source: string);
6465
match(url: string | URL): Match | null;
65-
static matcher(patterns: Array<string | RoutePattern>): Matcher;
6666
}
6767
```
6868

6969
**Match**
7070

7171
```ts
7272
type Match = {
73-
params: Record<string, string>;
74-
}
75-
```
76-
77-
**Matcher**
78-
79-
```ts
80-
type Matcher = {
81-
match(url: string | URL): Match | null;
82-
matchAll(url: string | URL): Array<Match>;
83-
}
73+
params: Record<string, string | undefined>;
74+
};
8475
```
8576

8677
## Concepts
@@ -196,4 +187,4 @@ let pattern = new RoutePattern('files/:filename.{jpg,png,gif}');
196187

197188
pattern.match('https://remix.run/files/logo.png');
198189
// { params: { filename: 'logo' } }
199-
```
190+
```

0 commit comments

Comments
 (0)