Generic type 'Component<P, S>' requires 2 type argument(s)

Viewed 7304

I'm trying to use ts and react-router v4 to make a demo, and I will get the error.

Failed to compile.

Error in D:\data\code\taven\react-components-usage-ts\node_modules\@types\react-router\lib\withRouter.d.ts

(3,99): error TS2314: Generic type 'PureComponent<P, S>' requires 2 type argument(s).
3 Answers
Related