Adobe Brackets禁用jslint但允许jshint [英] Adobe Brackets disable jslint but allow jshint
问题描述
我的基本问题:在Adobe Brackets编辑器中,如何在关闭或禁用jslint的同时使用jshint?
My basic question: In the Adobe Brackets editor how do I use jshint while turning off or disabling jslint?
我的tl; dr:在Adobe Brackets编辑器中对javascript进行衬里处理时,我发现同时获得了jslint和jshint的结果.虽然我已按自己的喜好配置了jshint,但我永远无法避免出现警告符号,该符号指示我无法通过jslint,因此它总是看起来像是棉绒存在问题.我只想使用jshint,因为通过.jshintrc文件全局配置它的功能非常有用,但是我看不到关闭jslint并仍然允许jshint的方法.有人知道该怎么做吗?
My tl;dr: When linting javascript in the Adobe Brackets editor I find that I get results for both jslint and jshint. While I have jshint configured to my liking I can never avoid the warning symbol that appears indicating I have failed to pass jslint so it always looks like there are problems with my linting. I only want to use jshint as the ability to globally configure it via the .jshintrc file is quite useful but I don't see a way to turn off jslint and still permit jshint. Anyone know how to do this?
我想我可以转储jshint并只使用jslint,但是由于后者需要直接将配置卡在JS文件中,所以我不想这样做.
I suppose I could dump jshint and just use jslint but since the latter requires the configuration to be stuck directly in the JS file I don't want to do this.
推荐答案
您现在可以将首选的短绒添加到Brackets的首选项文件中:
You can now add your preferred linters to Brackets' preferences file:
"language": {
"javascript": {
"linting.prefer": ["JSHint"],
"linting.usePreferredOnly": true
}
},
使用Debug > Open Preferences File
打开首选项文件.
这篇关于Adobe Brackets禁用jslint但允许jshint的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!