Getting a flood of TS2717 Typescript errors when running your application?
Deleting the @types
-package mentioned in the logs from the node-modules/@types
folder and upgrading it again using yarn
should solve the problem.
@types/react-redux
is complaining about subsequent property declarations (see logs below).
This can be fixed with the following commands.
$ rm -r node_modules/@types/react-redux
$ yarn upgrade @types/react-redux -E -D
Output from running application:
ERROR in [at-loader] ./node_modules/@types/react-redux/node_modules/@types/react/index.d.ts:3918:13
TS2717: Subsequent property declarations must have the same type. Property 'textPath' must be of type 'SVGProps<SVGTextPathElement>', but here has type 'SVGProps<SVGTextPathElement>'.
ERROR in [at-loader] ./node_modules/@types/react-redux/node_modules/@types/react/index.d.ts:3919:13
TS2717: Subsequent property declarations must have the same type. Property 'tspan' must be of type 'SVGProps<SVGTSpanElement>', but here has type 'SVGProps<SVGTSpanElement>'.
ERROR in [at-loader] ./node_modules/@types/react-redux/node_modules/@types/react/index.d.ts:3921:13
TS2717: Subsequent property declarations must have the same type. Property 'use' must be of type 'SVGProps<SVGUseElement>', but here has type 'SVGProps<SVGUseElement>'.
ERROR in [at-loader] ./node_modules/@types/react-redux/node_modules/@types/react/index.d.ts:3921:13
TS2717: Subsequent property declarations must have the same type. Property 'view' must be of type 'SVGProps<SVGViewElement>', but here has type 'SVGProps<SVGViewElement>'.