How to fight tons of unresolved variables warning in WebStorm?

前端 未结 6 1825
陌清茗
陌清茗 2020-12-04 09:19

I have a function that takes data from server:

function getData(data){
    console.log(data.someVar);
}

WebStorm says that someVar

6条回答
  •  孤街浪徒
    2020-12-04 10:19

    To remove the warnings on The WebStorm IDE you can simply uncheck the inspection options for:

    • Unresolved Javascript function
    • Unresolved Javascript variable

    ps. this will remove the warnings on the IDE, but I don't think that is the best idea, because we will lost one of the best utilities in a IDE like Webstorm, which can worsen the quality of our code.

    Even so, if you want to follow in the menu: File > Settings > Editor > Inspections we can disable the Javascript warnings

    Like the following picture:

提交回复
热议问题