我已经搜索和查看了这个网站到处,但我只能找到答案的JSHint,而不是JSLint。为了消除“使用函数形式的严格使用”错误,我在/*jslint node: true */
中添加了一个错误。但是要禁用使用const
和let
的错误,我似乎找不到任何东西。JSHint有esversion: 6,但这在JSLint上不起作用。
发布于 2017-05-12 02:07:26
使用Preferences API:
var PreferencesManager = brackets.getModule("preferences/PreferencesManager");
prefs = PreferencesManager.getExtensionPrefs("jslint");
prefs.set("options.es6", true);
或将其设置为配置文件之一:
brackets.json
文件或者:
.brackets.json
文件:因此:
{
"jslint.options": {
"es6": true
}
}
参考资料
https://stackoverflow.com/questions/37378977
复制相似问题