|
1 | 1 | { |
2 | | - // JSHint Default Configuration File (as on JSHint website) |
3 | | - // See http://jshint.com/docs/ for more details |
| 2 | + // JSHint Default Configuration File (as on JSHint website) |
| 3 | + // See http://jshint.com/docs/ for more details |
4 | 4 |
|
5 | | - "esversion": 6, |
6 | | - // {int} Default ES version |
| 5 | + "esversion": 8, |
| 6 | + // {int} Default ES version |
7 | 7 |
|
8 | | - "maxerr": 50, |
9 | | - // {int} Maximum error before stopping |
| 8 | + "maxerr": 50, |
| 9 | + // {int} Maximum error before stopping |
10 | 10 |
|
11 | | - // Enforcing |
12 | | - "bitwise": true, |
13 | | - // true: Prohibit bitwise operators (&, |, ^, etc.) |
14 | | - "camelcase": false, |
15 | | - // true: Identifiers must be in camelCase |
16 | | - "curly": true, |
17 | | - // true: Require {} for every new block or scope |
18 | | - "eqeqeq": true, |
19 | | - // true: Require triple equals (===) for comparison |
20 | | - "forin": true, |
21 | | - // true: Require filtering for..in loops with obj.hasOwnProperty() |
22 | | - "freeze": true, |
23 | | - // true: prohibits overwriting prototypes of native objects such as Array, Date etc. |
24 | | - "immed": false, |
25 | | - // true: Require immediate invocations to be wrapped in parens e.g. `(function () { } ());` |
26 | | - "indent": 4, |
27 | | - // {int} Number of spaces to use for indentation |
28 | | - "latedef": false, |
29 | | - // true: Require variables/functions to be defined before being used |
30 | | - "newcap": false, |
31 | | - // true: Require capitalization of all constructor functions e.g. `new F()` |
32 | | - "noarg": true, |
33 | | - // true: Prohibit use of `arguments.caller` and `arguments.callee` |
34 | | - "noempty": true, |
35 | | - // true: Prohibit use of empty blocks |
36 | | - "nonbsp": true, |
37 | | - // true: Prohibit "non-breaking whitespace" characters. |
38 | | - "nonew": false, |
39 | | - // true: Prohibit use of constructors for side-effects (without assignment) |
40 | | - "plusplus": false, |
41 | | - // true: Prohibit use of `++` & `--` |
42 | | - "quotmark": false, |
43 | | - // Quotation mark consistency: |
44 | | - // false : do nothing (default) |
45 | | - // true : ensure whatever is used is consistent |
46 | | - // "single" : require single quotes |
47 | | - // "double" : require double quotes |
48 | | - "undef": true, |
49 | | - // true: Require all non-global variables to be declared (prevents global leaks) |
50 | | - "unused": "vars", |
51 | | - // Unused variables: |
52 | | - // true : all variables, last function parameter |
53 | | - // "vars" : all variables only |
54 | | - // "strict" : all variables, all function parameters |
55 | | - "strict": false, |
56 | | - // true: Requires all functions run in ES5 Strict Mode |
57 | | - "maxparams": false, |
58 | | - // {int} Max number of formal params allowed per function |
59 | | - "maxdepth": false, |
60 | | - // {int} Max depth of nested blocks (within functions) |
61 | | - "maxstatements": false, |
62 | | - // {int} Max number statements per function |
63 | | - "maxcomplexity": false, |
64 | | - // {int} Max cyclomatic complexity per function |
65 | | - "maxlen": false, |
66 | | - // {int} Max number of characters per line |
67 | | - "varstmt": false, |
68 | | - // true: Disallow any var statements. Only `let` and `const` are allowed. |
| 11 | + // Enforcing |
| 12 | + "bitwise": true, |
| 13 | + // true: Prohibit bitwise operators (&, |, ^, etc.) |
| 14 | + "camelcase": false, |
| 15 | + // true: Identifiers must be in camelCase |
| 16 | + "curly": true, |
| 17 | + // true: Require {} for every new block or scope |
| 18 | + "eqeqeq": true, |
| 19 | + // true: Require triple equals (===) for comparison |
| 20 | + "forin": true, |
| 21 | + // true: Require filtering for..in loops with obj.hasOwnProperty() |
| 22 | + "freeze": true, |
| 23 | + // true: prohibits overwriting prototypes of native objects such as Array, Date etc. |
| 24 | + "immed": false, |
| 25 | + // true: Require immediate invocations to be wrapped in parens e.g. `(function () { } ());` |
| 26 | + "indent": 4, |
| 27 | + // {int} Number of spaces to use for indentation |
| 28 | + "latedef": false, |
| 29 | + // true: Require variables/functions to be defined before being used |
| 30 | + "newcap": false, |
| 31 | + // true: Require capitalization of all constructor functions e.g. `new F()` |
| 32 | + "noarg": true, |
| 33 | + // true: Prohibit use of `arguments.caller` and `arguments.callee` |
| 34 | + "noempty": true, |
| 35 | + // true: Prohibit use of empty blocks |
| 36 | + "nonbsp": true, |
| 37 | + // true: Prohibit "non-breaking whitespace" characters. |
| 38 | + "nonew": false, |
| 39 | + // true: Prohibit use of constructors for side-effects (without assignment) |
| 40 | + "plusplus": false, |
| 41 | + // true: Prohibit use of `++` & `--` |
| 42 | + "quotmark": false, |
| 43 | + // Quotation mark consistency: |
| 44 | + // false : do nothing (default) |
| 45 | + // true : ensure whatever is used is consistent |
| 46 | + // "single" : require single quotes |
| 47 | + // "double" : require double quotes |
| 48 | + "undef": true, |
| 49 | + // true: Require all non-global variables to be declared (prevents global leaks) |
| 50 | + "unused": "vars", |
| 51 | + // Unused variables: |
| 52 | + // true : all variables, last function parameter |
| 53 | + // "vars" : all variables only |
| 54 | + // "strict" : all variables, all function parameters |
| 55 | + "strict": false, |
| 56 | + // true: Requires all functions run in ES5 Strict Mode |
| 57 | + "maxparams": false, |
| 58 | + // {int} Max number of formal params allowed per function |
| 59 | + "maxdepth": false, |
| 60 | + // {int} Max depth of nested blocks (within functions) |
| 61 | + "maxstatements": false, |
| 62 | + // {int} Max number statements per function |
| 63 | + "maxcomplexity": false, |
| 64 | + // {int} Max cyclomatic complexity per function |
| 65 | + "maxlen": false, |
| 66 | + // {int} Max number of characters per line |
| 67 | + "varstmt": false, |
| 68 | + // true: Disallow any var statements. Only `let` and `const` are allowed. |
69 | 69 |
|
70 | | - // Relaxing |
71 | | - "asi": false, |
72 | | - // true: Tolerate Automatic Semicolon Insertion (no semicolons) |
73 | | - "boss": false, |
74 | | - // true: Tolerate assignments where comparisons would be expected |
75 | | - "debug": false, |
76 | | - // true: Allow debugger statements e.g. browser breakpoints. |
77 | | - "eqnull": false, |
78 | | - // true: Tolerate use of `== null` |
79 | | - "es5": false, |
80 | | - // true: Allow ES5 syntax (ex: getters and setters) |
81 | | - "esnext": false, |
82 | | - // true: Allow ES.next (ES6) syntax (ex: `const`) |
83 | | - "moz": false, |
84 | | - // true: Allow Mozilla specific syntax (extends and overrides esnext features) |
85 | | - // (ex: `for each`, multiple try/catch, function expression…) |
86 | | - "evil": false, |
87 | | - // true: Tolerate use of `eval` and `new Function()` |
88 | | - "expr": false, |
89 | | - // true: Tolerate `ExpressionStatement` as Programs |
90 | | - "funcscope": false, |
91 | | - // true: Tolerate defining variables inside control statements |
92 | | - "globalstrict": false, |
93 | | - // true: Allow global "use strict" (also enables 'strict') |
94 | | - "iterator": false, |
95 | | - // true: Tolerate using the `__iterator__` property |
96 | | - "lastsemic": false, |
97 | | - // true: Tolerate omitting a semicolon for the last statement of a 1-line block |
98 | | - "laxbreak": false, |
99 | | - // true: Tolerate possibly unsafe line breakings |
100 | | - "laxcomma": false, |
101 | | - // true: Tolerate comma-first style coding |
102 | | - "loopfunc": false, |
103 | | - // true: Tolerate functions being defined in loops |
104 | | - "multistr": false, |
105 | | - // true: Tolerate multi-line strings |
106 | | - "noyield": false, |
107 | | - // true: Tolerate generator functions with no yield statement in them. |
108 | | - "notypeof": false, |
109 | | - // true: Tolerate invalid typeof operator values |
110 | | - "proto": false, |
111 | | - // true: Tolerate using the `__proto__` property |
112 | | - "scripturl": false, |
113 | | - // true: Tolerate script-targeted URLs |
114 | | - "shadow": false, |
115 | | - // true: Allows re-define variables later in code e.g. `var x=1; x=2;` |
116 | | - "sub": false, |
117 | | - // true: Tolerate using `[]` notation when it can still be expressed in dot notation |
118 | | - "supernew": false, |
119 | | - // true: Tolerate `new function () { ... };` and `new Object;` |
120 | | - "validthis": false, |
121 | | - // true: Tolerate using this in a non-constructor function |
| 70 | + // Relaxing |
| 71 | + "asi": false, |
| 72 | + // true: Tolerate Automatic Semicolon Insertion (no semicolons) |
| 73 | + "boss": false, |
| 74 | + // true: Tolerate assignments where comparisons would be expected |
| 75 | + "debug": false, |
| 76 | + // true: Allow debugger statements e.g. browser breakpoints. |
| 77 | + "eqnull": false, |
| 78 | + // true: Tolerate use of `== null` |
| 79 | + "es5": false, |
| 80 | + // true: Allow ES5 syntax (ex: getters and setters) |
| 81 | + "esnext": false, |
| 82 | + // true: Allow ES.next (ES6) syntax (ex: `const`) |
| 83 | + "moz": false, |
| 84 | + // true: Allow Mozilla specific syntax (extends and overrides esnext features) |
| 85 | + // (ex: `for each`, multiple try/catch, function expression…) |
| 86 | + "evil": false, |
| 87 | + // true: Tolerate use of `eval` and `new Function()` |
| 88 | + "expr": false, |
| 89 | + // true: Tolerate `ExpressionStatement` as Programs |
| 90 | + "funcscope": false, |
| 91 | + // true: Tolerate defining variables inside control statements |
| 92 | + "globalstrict": false, |
| 93 | + // true: Allow global "use strict" (also enables 'strict') |
| 94 | + "iterator": false, |
| 95 | + // true: Tolerate using the `__iterator__` property |
| 96 | + "lastsemic": false, |
| 97 | + // true: Tolerate omitting a semicolon for the last statement of a 1-line block |
| 98 | + "laxbreak": false, |
| 99 | + // true: Tolerate possibly unsafe line breakings |
| 100 | + "laxcomma": false, |
| 101 | + // true: Tolerate comma-first style coding |
| 102 | + "loopfunc": false, |
| 103 | + // true: Tolerate functions being defined in loops |
| 104 | + "multistr": false, |
| 105 | + // true: Tolerate multi-line strings |
| 106 | + "noyield": false, |
| 107 | + // true: Tolerate generator functions with no yield statement in them. |
| 108 | + "notypeof": false, |
| 109 | + // true: Tolerate invalid typeof operator values |
| 110 | + "proto": false, |
| 111 | + // true: Tolerate using the `__proto__` property |
| 112 | + "scripturl": false, |
| 113 | + // true: Tolerate script-targeted URLs |
| 114 | + "shadow": false, |
| 115 | + // true: Allows re-define variables later in code e.g. `var x=1; x=2;` |
| 116 | + "sub": false, |
| 117 | + // true: Tolerate using `[]` notation when it can still be expressed in dot notation |
| 118 | + "supernew": false, |
| 119 | + // true: Tolerate `new function () { ... };` and `new Object;` |
| 120 | + "validthis": false, |
| 121 | + // true: Tolerate using this in a non-constructor function |
122 | 122 |
|
123 | | - // Environments |
124 | | - "browser": true, |
125 | | - // Web Browser (window, document, etc) |
126 | | - "browserify": true, |
127 | | - // Browserify (node.js code in the browser) |
128 | | - "couch": false, |
129 | | - // CouchDB |
130 | | - "devel": true, |
131 | | - // Development/debugging (alert, confirm, etc) |
132 | | - "dojo": false, |
133 | | - // Dojo Toolkit |
134 | | - "jasmine": false, |
135 | | - // Jasmine |
136 | | - "jquery": false, |
137 | | - // jQuery |
138 | | - "mocha": true, |
139 | | - // Mocha |
140 | | - "mootools": false, |
141 | | - // MooTools |
142 | | - "node": false, |
143 | | - // Node.js |
144 | | - "nonstandard": false, |
145 | | - // Widely adopted globals (escape, unescape, etc) |
146 | | - "phantom": false, |
147 | | - // PhantomJS |
148 | | - "prototypejs": false, |
149 | | - // Prototype and Scriptaculous |
150 | | - "qunit": false, |
151 | | - // QUnit |
152 | | - "rhino": false, |
153 | | - // Rhino |
154 | | - "shelljs": false, |
155 | | - // ShellJS |
156 | | - "typed": false, |
157 | | - // Globals for typed array constructions |
158 | | - "worker": false, |
159 | | - // Web Workers |
160 | | - "wsh": false, |
161 | | - // Windows Scripting Host |
162 | | - "yui": false, |
163 | | - // Yahoo User Interface |
| 123 | + // Environments |
| 124 | + "browser": true, |
| 125 | + // Web Browser (window, document, etc) |
| 126 | + "browserify": true, |
| 127 | + // Browserify (node.js code in the browser) |
| 128 | + "couch": false, |
| 129 | + // CouchDB |
| 130 | + "devel": true, |
| 131 | + // Development/debugging (alert, confirm, etc) |
| 132 | + "dojo": false, |
| 133 | + // Dojo Toolkit |
| 134 | + "jasmine": false, |
| 135 | + // Jasmine |
| 136 | + "jquery": false, |
| 137 | + // jQuery |
| 138 | + "mocha": true, |
| 139 | + // Mocha |
| 140 | + "mootools": false, |
| 141 | + // MooTools |
| 142 | + "node": false, |
| 143 | + // Node.js |
| 144 | + "nonstandard": false, |
| 145 | + // Widely adopted globals (escape, unescape, etc) |
| 146 | + "phantom": false, |
| 147 | + // PhantomJS |
| 148 | + "prototypejs": false, |
| 149 | + // Prototype and Scriptaculous |
| 150 | + "qunit": false, |
| 151 | + // QUnit |
| 152 | + "rhino": false, |
| 153 | + // Rhino |
| 154 | + "shelljs": false, |
| 155 | + // ShellJS |
| 156 | + "typed": false, |
| 157 | + // Globals for typed array constructions |
| 158 | + "worker": false, |
| 159 | + // Web Workers |
| 160 | + "wsh": false, |
| 161 | + // Windows Scripting Host |
| 162 | + "yui": false, |
| 163 | + // Yahoo User Interface |
164 | 164 |
|
165 | | - // Custom Globals |
166 | | - // additional predefined global variables |
167 | | - "globals": { |
168 | | - "THREE": false, |
169 | | - "performance": false |
170 | | - } |
| 165 | + // Custom Globals |
| 166 | + // additional predefined global variables |
| 167 | + "globals": { |
| 168 | + "THREE": false, |
| 169 | + "performance": false |
| 170 | + } |
171 | 171 | } |
0 commit comments