diff --git a/types/react-router/index.d.ts b/types/react-router/index.d.ts index 2e1cfb902b..f62fc44b18 100644 --- a/types/react-router/index.d.ts +++ b/types/react-router/index.d.ts @@ -117,7 +117,7 @@ export interface match { // Omit taken from https://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-8.html export type Omit = Pick>; -export function matchPath(pathname: string, props: RouteProps, parent?: match | null): match | null; +export function matchPath(pathname: string, props: string | RouteProps, parent?: match | null): match | null; export function generatePath(pattern: string, params?: { [paramName: string]: string | number | boolean }): string;