Hi,
There is a bug in the Create-react-app CLI.
Currently if you use and old package.json that has the : react-scripts: ^3.1.1 version.
and you run npm i and then try to rum the site (npm start) you get the following error:
“Definition for rule '@typescript-eslint/consistent-type-assertions' was not found”
I solved this by deleting the node_module entirely, then I updated my package.json file to use the "react-scripts: 3.1.2" version. then i run the npm i again, and it fixed the issue.
It looks like the new create-react-app doesn't backward support the react-scripts: 3.1.1 version.
Please check this ASAP since I already see posts in StackOverflow, meaning a lot of people are going to encounter this issue.
Thanks.
Yeah I have the same issue. Updates - Upgrading to 3.1.2 version of react-scripts fixed the issue.
Please file this issue at https://github.com/facebook/create-react-app/issues, thanks!
thanks worked.
try this yarn add @typescript-eslint/eslint-plugin --save , worked for me
Most helpful comment
Yeah I have the same issue. Updates - Upgrading to 3.1.2 version of react-scripts fixed the issue.