1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-27 07:50:57 +01:00

Define a seperate JSHint configuration for NodeJS files

Summary: Currently, we assume that all JavaScript files are for use in a browser. This is not true for the NodeJS Aphlict server code. Split the current JSHint configuration into `jshint-browser` and `jshint-node`.

Test Plan: `arc lint`

Reviewers: #blessed_reviewers, epriestley

Reviewed By: #blessed_reviewers, epriestley

Subscribers: Korvin, epriestley

Differential Revision: https://secure.phabricator.com/D11071
This commit is contained in:
Joshua Spence 2014-12-30 03:01:58 -08:00 committed by epriestley
parent 07dbd520bd
commit b6e0c76c7d
3 changed files with 34 additions and 2 deletions

View file

@ -21,10 +21,20 @@
"(^support/aphlict/)"
]
},
"jshint": {
"jshint-browser": {
"type": "jshint",
"include": "(\\.js$)",
"jshint.jshintrc": "support/lint/jshintrc"
"exclude": [
"(^support/aphlict/server/.*\\.js$)"
],
"jshint.jshintrc": "support/lint/browser.jshintrc"
},
"jshint-node": {
"type": "jshint",
"include": [
"(^support/aphlict/server/.*\\.js$)"
],
"jshint.jshintrc": "support/lint/node.jshintrc"
},
"json": {
"type": "json",

View file

@ -0,0 +1,22 @@
{
"bitwise": true,
"curly": true,
"immed": true,
"indent": 2,
"latedef": true,
"newcap": true,
"noarg": true,
"quotmark": "single",
"undef": true,
"unused": true,
"expr": true,
"loopfunc": true,
"sub": true,
"globals": {
"JX": false,
"__DEV__": false
},
"node": true
}