find-my-way
Advanced tools
Comparing version 7.6.0 to 7.6.1
@@ -70,3 +70,3 @@ import { IncomingMessage, ServerResponse } from 'http'; | ||
}, | ||
validate(value: unknown): void, | ||
validate?(value: unknown): void, | ||
deriveConstraint<Context>(req: Req<V>, ctx?: Context) : T, | ||
@@ -73,0 +73,0 @@ } |
@@ -33,3 +33,3 @@ 'use strict' | ||
const { prettyPrintTree } = require('./lib/pretty-print') | ||
const { StaticNode, NODE_TYPES } = require('./custom_node') | ||
const { StaticNode, NODE_TYPES } = require('./lib/node') | ||
const Constrainer = require('./lib/constrainer') | ||
@@ -36,0 +36,0 @@ const httpMethods = require('./lib/http-methods') |
{ | ||
"name": "find-my-way", | ||
"version": "7.6.0", | ||
"version": "7.6.1", | ||
"description": "Crazy fast http radix based router", | ||
@@ -8,5 +8,5 @@ "main": "index.js", | ||
"scripts": { | ||
"bench": "node bench.js", | ||
"bench:cmp": "node bench-cmp.js", | ||
"bench:cmp:ci": "node bench-cmp.js --ci", | ||
"bench": "node ./benchmark/bench.js", | ||
"bench:cmp": "node ./benchmark/compare-branches.js", | ||
"bench:cmp:ci": "node ./benchmark/compare-branches.js --ci", | ||
"test:lint": "standard", | ||
@@ -13,0 +13,0 @@ "test:typescript": "tsd", |
@@ -13,3 +13,3 @@ # find-my-way | ||
- [API](#api) | ||
- [FindMyWay([options])](#find-my-way) | ||
- [FindMyWay([options])](#findmywayoptions) | ||
- [on(method, path, [opts], handler, [store])](#onmethod-path-opts-handler-store) | ||
@@ -734,3 +734,6 @@ - [Versioned routes](#versioned-routes) | ||
}, | ||
mustMatchWhenDerived: true // if the request is asking for a version, don't match un-version-constrained handlers | ||
mustMatchWhenDerived: true, // if the request is asking for a version, don't match un-version-constrained handlers | ||
validate (value) { // optional validate function, validates the assigned value at route-configuration (the .on function) time (not the runtime-value) | ||
assert(typeof value === 'string', 'Version should be a string') | ||
} | ||
} | ||
@@ -737,0 +740,0 @@ |
@@ -157,3 +157,2 @@ import { expectType } from 'tsd' | ||
}, | ||
validate(value: unknown): void {}, | ||
storage () { | ||
@@ -160,0 +159,0 @@ return { |
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
353158
767
8826