Stop Cloud9 IDE from giving me the warning message.
VarName is not defined, please fix or add /*global VarName*/
Now this bugs me and I want to fix it.
The obvious solution would be to just add the comment
/*global VarName*/ and be done with it, but I don’t believe this is a good practice.
What I tried
import functionality. In theory, this would allow me to do something like
import "myOtherJsFile" and be done with it.
This would be a good standardized solution for the problem, as many other languages take the same approach.
However, even after adding the said line, I still get the warning. It wont go away.
- Am I doing something wrong?
- Is there a way to remove the warning without adding comments to my code?
- Is there another way of achieving my objective?