mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-16 23:10:29 +00:00
adding constructor argument to hapi__call (#43774)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { Route, Router } from '@hapi/call';
|
||||
|
||||
const router = new Router();
|
||||
const router = new Router({ isCaseSensitive: false });
|
||||
|
||||
router.add({ method: 'get', path: '/user/{userId}'}, { id: 'get_user'});
|
||||
|
||||
|
||||
Vendored
+1
@@ -23,6 +23,7 @@ export interface Match<P = any, D = any> {
|
||||
export type Route<P = any, D = any> = Match<P, D> | Error;
|
||||
|
||||
export class Router {
|
||||
constructor(routerOptions?: RouterOptions)
|
||||
add(definition: RouteDefinition, data?: any): void;
|
||||
route(method: string, path: string): Route;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user