diff --git a/packages/react/package.json b/packages/react/package.json index 2b6f3c351900..82caea532df5 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -35,8 +35,8 @@ "@types/hoist-non-react-statics": "^3.3.1", "@types/react": "^17.0.3", "@types/react-router-3": "npm:@types/react-router@3.0.24", - "@types/react-router-4": "npm:@types/react-router@5.1.13", - "@types/react-router-5": "npm:@types/react-router@5.1.13", + "@types/react-router-4": "npm:@types/react-router@5.1.14", + "@types/react-router-5": "npm:@types/react-router@5.1.14", "eslint": "7.6.0", "eslint-plugin-react": "^7.20.5", "eslint-plugin-react-hooks": "^4.0.8", diff --git a/packages/react/src/reactrouter.tsx b/packages/react/src/reactrouter.tsx index 00a69d3b0ea8..a7d58c1a4aa9 100644 --- a/packages/react/src/reactrouter.tsx +++ b/packages/react/src/reactrouter.tsx @@ -23,18 +23,6 @@ export type RouteConfig = { routes?: RouteConfig[]; }; -interface RouteProps { - [propName: string]: any; - location?: Location; - component?: React.ComponentType | React.ComponentType; - render?: (props: any) => React.ReactNode; - children?: ((props: any) => React.ReactNode) | React.ReactNode; - path?: string | string[]; - exact?: boolean; - sensitive?: boolean; - strict?: boolean; -} - type MatchPath = (pathname: string, props: string | string[] | any, parent?: Match | null) => Match | null; /* eslint-enable @typescript-eslint/no-explicit-any */ @@ -148,9 +136,7 @@ function computeRootMatch(pathname: string): Match { } // eslint-disable-next-line @typescript-eslint/no-explicit-any -export function withSentryRouting

>( - Route: React.ComponentType

, -): React.FC

{ +export function withSentryRouting

>(Route: React.ComponentType

): React.FC

{ const componentDisplayName = Route.displayName || Route.name; const WrappedRoute: React.FC

= (props: P) => { diff --git a/yarn.lock b/yarn.lock index c540a546ba46..98aca26eac47 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3300,10 +3300,10 @@ "@types/history" "^3" "@types/react" "*" -"@types/react-router-4@npm:@types/react-router@5.1.13", "@types/react-router-5@npm:@types/react-router@5.1.13": - version "5.1.13" - resolved "https://registry.yarnpkg.com/@types/react-router/-/react-router-5.1.13.tgz#051c0d229bd48ad90558a1db500708127cc512f7" - integrity sha512-ZIuaO9Yrln54X6elg8q2Ivp6iK6p4syPsefEYAhRDAoqNh48C8VYUmB9RkXjKSQAJSJV0mbIFCX7I4vZDcHrjg== +"@types/react-router-4@npm:@types/react-router@5.1.14", "@types/react-router-5@npm:@types/react-router@5.1.14": + version "5.1.14" + resolved "https://registry.yarnpkg.com/@types/react-router/-/react-router-5.1.14.tgz#e0442f4eb4c446541ad7435d44a97f8fe6df40da" + integrity sha512-LAJpqYUaCTMT2anZheoidiIymt8MuX286zoVFPM3DVb23aQBH0mAkFvzpd4LKqiolV8bBtZWT5Qp7hClCNDENw== dependencies: "@types/history" "*" "@types/react" "*" @@ -14454,7 +14454,7 @@ neo-async@^2.5.0, neo-async@^2.6.0, neo-async@^2.6.1, neo-async@^2.6.2: resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== -next@^10.1.3: +next@10.1.3: version "10.1.3" resolved "https://registry.yarnpkg.com/next/-/next-10.1.3.tgz#e26e8371343a42bc2ba9be5cb253a7d324d03673" integrity sha512-8Jf38F+s0YcXXkJGF5iUxOqSmbHrey0fX5Epc43L0uwDKmN2jK9vhc2ihCwXC1pmu8d2m/8wfTiXRJKGti55yw==