path-to-regexp
Advanced tools
Comparing version 4.0.0 to 4.0.1
@@ -289,3 +289,3 @@ /** | ||
function stringToRegexp(path, keys, options) { | ||
return tokensToRegExp(parse(path, options), keys, options); | ||
return tokensToRegexp(parse(path, options), keys, options); | ||
} | ||
@@ -295,3 +295,3 @@ /** | ||
*/ | ||
export function tokensToRegExp(tokens, keys, options) { | ||
export function tokensToRegexp(tokens, keys, options) { | ||
if (options === void 0) { options = {}; } | ||
@@ -298,0 +298,0 @@ var strict = options.strict, _a = options.start, start = _a === void 0 ? true : _a, _b = options.end, end = _b === void 0 ? true : _b, _c = options.delimiter, delimiter = _c === void 0 ? DEFAULT_DELIMITER : _c; |
@@ -92,4 +92,4 @@ export interface ParseOptions { | ||
*/ | ||
export declare function tokensToRegExp(tokens: Token[], keys?: Key[], options?: RegExpOptions): RegExp; | ||
export interface RegExpOptions { | ||
export declare function tokensToRegexp(tokens: Token[], keys?: Key[], options?: RegexpOptions): RegExp; | ||
export interface RegexpOptions { | ||
/** | ||
@@ -137,2 +137,2 @@ * When `true` the regexp will be case sensitive. (default: `false`) | ||
*/ | ||
export declare function pathToRegexp(path: Path, keys?: Key[], options?: RegExpOptions & ParseOptions): RegExp; | ||
export declare function pathToRegexp(path: Path, keys?: Key[], options?: RegexpOptions & ParseOptions): RegExp; |
@@ -297,3 +297,3 @@ "use strict"; | ||
function stringToRegexp(path, keys, options) { | ||
return tokensToRegExp(parse(path, options), keys, options); | ||
return tokensToRegexp(parse(path, options), keys, options); | ||
} | ||
@@ -303,3 +303,3 @@ /** | ||
*/ | ||
function tokensToRegExp(tokens, keys, options) { | ||
function tokensToRegexp(tokens, keys, options) { | ||
if (options === void 0) { options = {}; } | ||
@@ -359,3 +359,3 @@ var strict = options.strict, _a = options.start, start = _a === void 0 ? true : _a, _b = options.end, end = _b === void 0 ? true : _b, _c = options.delimiter, delimiter = _c === void 0 ? DEFAULT_DELIMITER : _c; | ||
} | ||
exports.tokensToRegExp = tokensToRegExp; | ||
exports.tokensToRegexp = tokensToRegexp; | ||
/** | ||
@@ -362,0 +362,0 @@ * Normalize the given path string, returning a regular expression. |
{ | ||
"name": "path-to-regexp", | ||
"description": "Express style path to RegExp utility", | ||
"version": "4.0.0", | ||
"version": "4.0.1", | ||
"main": "dist/index.js", | ||
@@ -6,0 +6,0 @@ "typings": "dist/index.d.ts", |
@@ -236,3 +236,3 @@ # Path-to-RegExp | ||
- `tokensToRegExp(tokens, keys?, options?)` Transform an array of tokens into a matching regular expression. | ||
- `tokensToRegexp(tokens, keys?, options?)` Transform an array of tokens into a matching regular expression. | ||
- `tokensToFunction(tokens)` Transform an array of tokens into a path generator function. | ||
@@ -239,0 +239,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
0