@cloudflare/util-routes 5.4.1 → 5.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/useMatchRoute.d.ts +2 -12
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/dist/useMatchRoute.d.ts
CHANGED
|
@@ -1,16 +1,6 @@
|
|
|
1
1
|
import { ExtractParam, RouteParams, RoutePatternResult } from './route';
|
|
2
|
-
export
|
|
3
|
-
|
|
4
|
-
* Should be `true` if the static portions of the `path` should be matched in
|
|
5
|
-
* the same case.
|
|
6
|
-
*/
|
|
7
|
-
caseSensitive?: boolean;
|
|
8
|
-
/**
|
|
9
|
-
* Should be `true` if this pattern should match the entire URL pathname.
|
|
10
|
-
*/
|
|
11
|
-
end?: boolean;
|
|
12
|
-
}
|
|
13
|
-
export declare function useMatchRoute<T extends RoutePatternResult<any>>(route: T, useMatch: (str: string | PathPattern) => any, options?: PathPattern): PathMatch<RouteParams<ExtractParam<T>>> | null;
|
|
2
|
+
export declare type PathPatternOptions = Omit<PathPattern<string>, 'path'>;
|
|
3
|
+
export declare function useMatchRoute<T extends RoutePatternResult<any>>(route: T, useMatch: (str: string | PathPattern) => any, options?: PathPatternOptions): PathMatch<RouteParams<ExtractParam<T>>> | null;
|
|
14
4
|
/**
|
|
15
5
|
* A PathMatch contains info about how a PathPattern matched on a URL pathname.
|
|
16
6
|
*/
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudflare/util-routes",
|
|
3
3
|
"description": "Wraps path-to-regexp with a convenient, type-safe tagged template function",
|
|
4
|
-
"version": "5.4.
|
|
4
|
+
"version": "5.4.2",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
7
7
|
"author": "Frontend Team <frontend@cloudflare.com>",
|