Use global variable shown issue in sonarqube in javascript nodejs

40 Views Asked by At

Sonarqube is showing issue "When a non-existent variable is referenced a ReferenceError is raised" in Node JS even I mentioned variable as globally in another file.

I declared a variable like global.variable=TestData.

I can access this variable in the another files without any issues but when I execute sonar scan I am getting the issue mentioned.

Please advise this how to solve this.

0

There are 0 best solutions below