How to stop VS Code from erroring with `Cannot find name 'React'.ts(2304)`?
VS Code is complaining with
Cannot find name 'React'.ts(2304)
but I am not using React at all. I have both of these in my ts config:
How to I avoid this issue in VS Code?3 Replies
I'm curious how you made the app. Did you run: npx degit solidjs/templates/js my-app?
No, that application was more of less built from scratch manually more of less (it was a while ago so I don't remember 100%)
If you have an "include" property in tsconfig.json with directories listed, but you create a tsx file outside the included directories, this problem will happen. Either move your tsx file to an included directory or add the directory to the "include" property in tsconfig.json.