Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Adobe Brackets disable jslint but allow jshint

My basic question: In the Adobe Brackets editor how do I use jshint while turning off or disabling jslint?

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?

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.

like image 461
rg88 Avatar asked Dec 20 '14 21:12

rg88


Video Answer


2 Answers

You can now add your preferred linters to Brackets' preferences file:

"language": {     "javascript": {         "linting.prefer": ["JSHint"],         "linting.usePreferredOnly": true     } }, 

Open the preferences file with Debug > Open Preferences File.

Brackets preferences
Example preferences.json file

like image 133
David Lane Avatar answered Oct 03 '22 11:10

David Lane


To have multiple linters while still disabling jslint use the above plus this:

    "linting.prefer": [         "JSHint",         "JSCS"     ], 
like image 22
Post Impatica Avatar answered Oct 03 '22 09:10

Post Impatica