-
Notifications
You must be signed in to change notification settings - Fork 0
/
.jshintrc
42 lines (39 loc) · 2.36 KB
/
.jshintrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
{
//--------------------------------------------
// Enforcing Options
//--------------------------------------------
"camelcase": true, // Require all variable names to use either camelCase style or UPPER_CASE with underscores
"curly": true, // Require `{}` for every new block or scope
//"eqeqeq": true, // Require triple equals (`===`) for comparison
"forin": true, // Require `for in` loops to filter object's items (i.e. hasOwnProperty)
"indent": 4, // Require a specific tab width
//"latedef": true, // Require variables/functions to be defined before being used
"newcap": true, // Require capitalization of all constructor functions e.g. `new F()`
"noempty": true, // Require all blocks to be non-empty
"quotmark": "single", // Require the use of single quotes for strings
"undef": true, // Require all non-global variables to be declared
"unused": true, // Require all defined variables to be used
"trailing": true, // Require all lines to end without trailing whitespace
//"maxparams": 3 // Set the maximum number of formal parameters per function
//"maxlen": 100 // Set the maximum length of a line
//--------------------------------------------
// Relaxing Options
//--------------------------------------------
"boss": true, // Tolerate assignments where comparisons would be expected (i.e. `if(a = true) { ... }`)
"eqnull": true, // Tolerate use of `== null`
"funcscope": true, // Tolerate use of variables inside of control structures
"sub": true, // Tolerate using `[]` notation when it can still be expressed in dot notation
//--------------------------------------------
// Environments
//--------------------------------------------
"browser": true, // Enable browser globals (e.g. `window`, `document`)
"devel": true, // Enable development globals (e.g. `alert`, `console`)
"node": true, // Enable globals exposed by NodeJS (e.g. `require`, `module`)
"jquery": true, // Enable globals exposed by jQuery (e.g. `$`/`jQuery`)
//--------------------------------------------
// Additional Globals
//--------------------------------------------
"globals": {
"angular": true
}
}