Skip to content

Commit 0323214

Browse files
committed
eslintrc
1 parent 118161e commit 0323214

File tree

1 file changed

+232
-0
lines changed

1 file changed

+232
-0
lines changed

.eslintrc.js

Lines changed: 232 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,232 @@
1+
var OFF = 0, WARN = 1, ERROR = 2;
2+
3+
module.exports = exports = {
4+
"env": {
5+
"es6": true,
6+
"node": true,
7+
"browser": true
8+
},
9+
10+
"extends": "eslint:recommended",
11+
12+
// "ecmaFeatures": {
13+
// // env=es6 doesn't include modules, which we are using
14+
// "modules": true
15+
// },
16+
//
17+
18+
"rules": {
19+
"no-console": "off"
20+
},
21+
22+
"globals": {
23+
"W": "writable",
24+
"node": "writable",
25+
"J": "writable",
26+
"JSUS": "writable"
27+
}
28+
29+
//
30+
// "rules": {
31+
// // Possible Errors (overrides from recommended set)
32+
// "no-extra-parens": ERROR,
33+
// "no-unexpected-multiline": ERROR,
34+
// // All JSDoc comments must be valid
35+
// "valid-jsdoc": [ ERROR, {
36+
// "requireReturn": false,
37+
// "requireReturnDescription": false,
38+
// "requireParamDescription": true,
39+
// "prefer": {
40+
// "return": "returns"
41+
// }
42+
// }],
43+
//
44+
// // Best Practices
45+
//
46+
// // Allowed a getter without setter, but all setters require getters
47+
// "accessor-pairs": [ ERROR, {
48+
// "getWithoutSet": false,
49+
// "setWithoutGet": true
50+
// }],
51+
// "block-scoped-var": WARN,
52+
// "consistent-return": ERROR,
53+
// "curly": ERROR,
54+
// "default-case": WARN,
55+
// // the dot goes with the property when doing multiline
56+
// "dot-location": [ WARN, "property" ],
57+
// "dot-notation": WARN,
58+
// "eqeqeq": [ ERROR, "smart" ],
59+
// "guard-for-in": WARN,
60+
// "no-alert": ERROR,
61+
// "no-caller": ERROR,
62+
// "no-case-declarations": WARN,
63+
// "no-div-regex": WARN,
64+
// "no-else-return": WARN,
65+
// "no-empty-label": WARN,
66+
// "no-empty-pattern": WARN,
67+
// "no-eq-null": WARN,
68+
// "no-eval": ERROR,
69+
// "no-extend-native": ERROR,
70+
// "no-extra-bind": WARN,
71+
// "no-floating-decimal": WARN,
72+
// "no-implicit-coercion": [ WARN, {
73+
// "boolean": true,
74+
// "number": true,
75+
// "string": true
76+
// }],
77+
// "no-implied-eval": ERROR,
78+
// "no-invalid-this": ERROR,
79+
// "no-iterator": ERROR,
80+
// "no-labels": WARN,
81+
// "no-lone-blocks": WARN,
82+
// "no-loop-func": ERROR,
83+
// "no-magic-numbers": WARN,
84+
// "no-multi-spaces": ERROR,
85+
// "no-multi-str": WARN,
86+
// "no-native-reassign": ERROR,
87+
// "no-new-func": ERROR,
88+
// "no-new-wrappers": ERROR,
89+
// "no-new": ERROR,
90+
// "no-octal-escape": ERROR,
91+
// "no-param-reassign": ERROR,
92+
// "no-process-env": WARN,
93+
// "no-proto": ERROR,
94+
// "no-redeclare": ERROR,
95+
// "no-return-assign": ERROR,
96+
// "no-script-url": ERROR,
97+
// "no-self-compare": ERROR,
98+
// "no-throw-literal": ERROR,
99+
// "no-unused-expressions": ERROR,
100+
// "no-useless-call": ERROR,
101+
// "no-useless-concat": ERROR,
102+
// "no-void": WARN,
103+
// // Produce warnings when something is commented as TODO or FIXME
104+
// "no-warning-comments": [ WARN, {
105+
// "terms": [ "TODO", "FIXME" ],
106+
// "location": "start"
107+
// }],
108+
// "no-with": WARN,
109+
// "radix": WARN,
110+
// "vars-on-top": ERROR,
111+
// // Enforces the style of wrapped functions
112+
// "wrap-iife": [ ERROR, "outside" ],
113+
// "yoda": ERROR,
114+
//
115+
// // Strict Mode - for ES6, never use strict.
116+
// "strict": [ ERROR, "never" ],
117+
//
118+
// // Variables
119+
// "init-declarations": [ ERROR, "always" ],
120+
// "no-catch-shadow": WARN,
121+
// "no-delete-var": ERROR,
122+
// "no-label-var": ERROR,
123+
// "no-shadow-restricted-names": ERROR,
124+
// "no-shadow": WARN,
125+
// // We require all vars to be initialized (see init-declarations)
126+
// // If we NEED a var to be initialized to undefined,
127+
// // it needs to be explicit
128+
// "no-undef-init": OFF,
129+
// "no-undef": ERROR,
130+
// "no-undefined": OFF,
131+
// "no-unused-vars": WARN,
132+
// // Disallow hoisting - let & const don't allow hoisting anyhow
133+
// "no-use-before-define": ERROR,
134+
//
135+
// // Node.js and CommonJS
136+
// "callback-return": [ WARN, [ "callback", "next" ]],
137+
// "global-require": ERROR,
138+
// "handle-callback-err": WARN,
139+
// "no-mixed-requires": WARN,
140+
// "no-new-require": ERROR,
141+
// // Use path.concat instead
142+
// "no-path-concat": ERROR,
143+
// "no-process-exit": ERROR,
144+
// "no-restricted-modules": OFF,
145+
// "no-sync": WARN,
146+
//
147+
// // ECMAScript 6 support
148+
// "arrow-body-style": [ ERROR, "always" ],
149+
// "arrow-parens": [ ERROR, "always" ],
150+
// "arrow-spacing": [ ERROR, { "before": true, "after": true }],
151+
// "constructor-super": ERROR,
152+
// "generator-star-spacing": [ ERROR, "before" ],
153+
// "no-arrow-condition": ERROR,
154+
// "no-class-assign": ERROR,
155+
// "no-const-assign": ERROR,
156+
// "no-dupe-class-members": ERROR,
157+
// "no-this-before-super": ERROR,
158+
// "no-var": WARN,
159+
// "object-shorthand": [ WARN, "never" ],
160+
// "prefer-arrow-callback": WARN,
161+
// "prefer-spread": WARN,
162+
// "prefer-template": WARN,
163+
// "require-yield": ERROR,
164+
//
165+
// // Stylistic - everything here is a warning because of style.
166+
// "array-bracket-spacing": [ WARN, "always" ],
167+
// "block-spacing": [ WARN, "always" ],
168+
// "brace-style": [ WARN, "1tbs", { "allowSingleLine": false } ],
169+
// "camelcase": WARN,
170+
// "comma-spacing": [ WARN, { "before": false, "after": true } ],
171+
// "comma-style": [ WARN, "last" ],
172+
// "computed-property-spacing": [ WARN, "never" ],
173+
// "consistent-this": [ WARN, "self" ],
174+
// "eol-last": WARN,
175+
// "func-names": WARN,
176+
// "func-style": [ WARN, "declaration" ],
177+
// "id-length": [ WARN, { "min": 2, "max": 32 } ],
178+
// "indent": [ WARN, 4 ],
179+
// "jsx-quotes": [ WARN, "prefer-double" ],
180+
// // "linebreak-style": [ WARN, "unix" ],
181+
// "lines-around-comment": [ WARN, { "beforeBlockComment": true } ],
182+
// "max-depth": [ WARN, 8 ],
183+
// "max-len": [ WARN, 132 ],
184+
// "max-nested-callbacks": [ WARN, 8 ],
185+
// "max-params": [ WARN, 8 ],
186+
// "new-cap": WARN,
187+
// "new-parens": WARN,
188+
// "no-array-constructor": WARN,
189+
// "no-bitwise": OFF,
190+
// "no-continue": OFF,
191+
// "no-inline-comments": OFF,
192+
// "no-lonely-if": WARN,
193+
// "no-mixed-spaces-and-tabs": WARN,
194+
// "no-multiple-empty-lines": WARN,
195+
// "no-negated-condition": OFF,
196+
// "no-nested-ternary": WARN,
197+
// "no-new-object": WARN,
198+
// "no-plusplus": OFF,
199+
// "no-spaced-func": WARN,
200+
// "no-ternary": OFF,
201+
// "no-trailing-spaces": WARN,
202+
// "no-underscore-dangle": WARN,
203+
// "no-unneeded-ternary": WARN,
204+
// "object-curly-spacing": [ WARN, "always" ],
205+
// "one-var": OFF,
206+
// "operator-assignment": [ WARN, "never" ],
207+
// "operator-linebreak": [ WARN, "after" ],
208+
// "padded-blocks": [ WARN, "never" ],
209+
// "quote-props": [ WARN, "consistent-as-needed" ],
210+
// // "quotes": [ WARN, "single" ],
211+
// "require-jsdoc": [ WARN, {
212+
// "require": {
213+
// "FunctionDeclaration": true,
214+
// "MethodDefinition": true,
215+
// "ClassDeclaration": false
216+
// }
217+
// }],
218+
// "semi-spacing": [ WARN, { "before": false, "after": true }],
219+
// "semi": [ ERROR, "always" ],
220+
// "sort-vars": OFF,
221+
// "space-after-keywords": [ WARN, "always" ],
222+
// "space-before-blocks": [ WARN, "always" ],
223+
// "space-before-function-paren": [ WARN, "never" ],
224+
// "space-before-keywords": [ WARN, "always" ],
225+
// "space-in-parens": [ WARN, "never" ],
226+
// "space-infix-ops": [ WARN, { "int32Hint": true } ],
227+
// "space-return-throw-case": ERROR,
228+
// "space-unary-ops": ERROR,
229+
// "spaced-comment": [ WARN, "always" ],
230+
// "wrap-regex": WARN
231+
// }
232+
};

0 commit comments

Comments
 (0)