2
我在文件中的下列對象remover.js:JSHint抱怨對象
'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
如何移除此警告?