我在文件remover.js中有以下对象:
'use strict';
(function( remover, $, undefined ) {
// ...
// Object's definition
// ...
}( window.remover = window.remover || {}, jQuery ));
这是在外部文件main.js中使用的:
'use strict';
remover.doSomething();
代码正常运行,但JSHint出现以下问题:
Running "jshint:all" (jshint) task
app/scripts/stuff/main.js
line 3 col 1 'remover' is not defined.
✖ 1 problem
如何消除此警告?