javascript - JsHint {a} is not defined -
i need disable rule 117 jshint specific line, @ moment using /*jshint -w117 */ no success.
any idea how fix it?
_createdom: function () { //jscs:disable maximumlinelength var template = ''; /*jshint -w117 */ template += dojoconfig.app.hastools ? '<div id="paneldevelopment"></div>' : ''; template += '<div id="boundingboxes">'; //jscs:enable maximumlinelength } }; notes: seems working when /*jshint -w117 */ placed @ beginning of js file , not inside method.
at time of writing couldn't work either; might need open bug. disabling rule didn't work when tried, though others seemed work in same context.
as alternative, can specify white list of global variables via /* globals dojoconfig */ @ top of file as inline configuration; might better explicitly declare undefined variables enable them entirely anyway. same @ project as linter option.
Comments
Post a Comment