So I am building a REACT JS project, and after a while I noticed that it doesn't underline undefined functions nor wrong imports, for example if I does that:
import React, { useState } from 'reactaeasdfas';
it wont say that reactaeasdfas is undefined.
After a bit of searching I found that people say that jsconfig.json should be initialized.
I found a basic one on the internet:
{
"compilerOptions": {
"module": "commonjs",
"target": "es6",
"jsx": "react"
},
"include": [
"src"
]
}
This code above does solve the problem that if I call an undefined function, it will underline it in red, but it still doesn't work if I include undefined import.
Note: I installed react project via create-react-app