Skip to content

Commit 91898e9

Browse files
committed
rc files for linting
1 parent f29f01e commit 91898e9

File tree

2 files changed

+258
-0
lines changed

2 files changed

+258
-0
lines changed

.eslintrc

Lines changed: 152 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,152 @@
1+
{
2+
"rules": {
3+
"no-cond-assign": 2,
4+
"no-constant-condition": 2,
5+
"no-comma-dangle": 2,
6+
"no-control-regex": 2,
7+
"no-debugger": 2,
8+
"no-dupe-keys": 2,
9+
"no-empty": 2,
10+
"no-extra-semi": 2,
11+
"no-inner-declarations": 2,
12+
"no-invalid-regexp": 2,
13+
"no-negated-in-lhs": 2,
14+
"no-obj-calls": 2,
15+
"no-regex-spaces": 2,
16+
"no-sparse-arrays": 2,
17+
"no-unreachable": 2,
18+
"use-isnan": 2,
19+
"valid-typeof": 2,
20+
"camelcase": 2,
21+
"eqeqeq": 2,
22+
"no-plusplus": 2,
23+
"no-bitwise": 2,
24+
"block-scoped-var": 2,
25+
"consistent-return": 2,
26+
"curly": [
27+
2,
28+
"all"
29+
],
30+
"default-case": 2,
31+
"dot-notation": 2,
32+
"no-caller": 2,
33+
"no-div-regex": 2,
34+
"no-else-return": 2,
35+
"no-empty-label": 2,
36+
"no-eq-null": 2,
37+
"no-eval": 2,
38+
"no-extend-native": 2,
39+
"no-fallthrough": 2,
40+
"no-floating-decimal": 2,
41+
"no-implied-eval": 2,
42+
"no-labels": 2,
43+
"no-iterator": 2,
44+
"no-lone-blocks": 2,
45+
"no-loop-func": 2,
46+
"no-multi-str": 2,
47+
"no-native-reassign": 2,
48+
"no-new": 2,
49+
"no-new-func": 2,
50+
"no-new-wrappers": 2,
51+
"no-octal": 2,
52+
"no-octal-escape": 2,
53+
"no-proto": 2,
54+
"no-redeclare": 2,
55+
"no-return-assign": 2,
56+
"no-script-url": 2,
57+
"no-self-compare": 2,
58+
"no-sequences": 2,
59+
"no-unused-expressions": 2,
60+
"no-with": 2,
61+
"yoda": 2,
62+
"radix": 2,
63+
"wrap-iife": [
64+
2,
65+
"outside"
66+
],
67+
"global-strict": [2, "never"],
68+
"no-extra-strict": 2,
69+
"strict": 2,
70+
"no-catch-shadow": 2,
71+
"no-delete-var": 2,
72+
"no-label-var": 2,
73+
"no-shadow": 2,
74+
"no-shadow-restricted-names": 2,
75+
"no-undef": 2,
76+
"no-undef-init": 2,
77+
"no-unused-vars": [
78+
2,
79+
{
80+
"vars": "all",
81+
"args": "after-used"
82+
}
83+
],
84+
"no-use-before-define": 2,
85+
"brace-style": [
86+
2,
87+
"1tbs"
88+
],
89+
"consistent-this": [
90+
2,
91+
"that"
92+
],
93+
"new-cap": 2,
94+
"new-parens": 2,
95+
"no-nested-ternary": 2,
96+
"no-array-constructor": 2,
97+
"no-lonely-if": 2,
98+
"no-new-object": 2,
99+
"no-spaced-func": 2,
100+
"no-space-before-semi": 2,
101+
"no-wrap-func": 2,
102+
"quotes": [
103+
2,
104+
"single",
105+
"avoid-escape"
106+
],
107+
"quote-props": 2,
108+
"semi": [
109+
2,
110+
"always"
111+
],
112+
"space-after-keywords": [
113+
2,
114+
"always"
115+
],
116+
"space-in-brackets": [
117+
2,
118+
"never"
119+
],
120+
"space-infix-ops": 2,
121+
"space-return-throw-case": 2,
122+
"space-unary-ops": 2,
123+
"one-var": 2,
124+
"wrap-regex": 2,
125+
"no-underscore-dangle": 2,
126+
127+
"no-extra-boolean-cast": 1,
128+
"no-console": 1,
129+
"no-alert": 1,
130+
"no-empty-class": 1,
131+
"no-ex-assign": 1,
132+
"no-func-assign": 1,
133+
"valid-jsdoc": 1,
134+
"guard-for-in": 1,
135+
"no-warning-comments": [
136+
1,
137+
{
138+
"terms": ["todo", "fixme", "xxx"],
139+
"location": "anywhere"
140+
}
141+
],
142+
"func-style": [
143+
1,
144+
"expression"
145+
],
146+
"no-extra-parens": 1,
147+
"func-names": 1,
148+
149+
"no-ternary": 0,
150+
"sort-vars": 0
151+
}
152+
}

.jscsrc

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
{
2+
"validateIndentation": 2,
3+
"disallowAnonymousFunctions": true,
4+
"disallowCapitalizedComments": true,
5+
"disallowDanglingUnderscores": true,
6+
"disallowEmptyBlocks": true,
7+
"disallowFunctionDeclarations": true,
8+
"disallowImplicitTypeConversion": [
9+
"numeric",
10+
"binary",
11+
"string"
12+
],
13+
"disallowKeywordsOnNewLine": [
14+
"else"
15+
],
16+
"disallowKeywords": [
17+
"with"
18+
],
19+
"disallowMixedSpacesAndTabs": true,
20+
"disallowMultipleLineBreaks": true,
21+
"disallowMultipleLineStrings": true,
22+
"disallowMultipleSpaces": true,
23+
"disallowNewlineBeforeBlockStatements": true,
24+
"disallowNotOperatorsInConditionals": true,
25+
"disallowOperatorBeforeLineBreak": [
26+
".",
27+
"+"
28+
],
29+
"disallowSpacesInCallExpression": true,
30+
"disallowYodaConditions": true,
31+
"requireBlocksOnNewline": true,
32+
"requireCurlyBraces": [
33+
"if",
34+
"else",
35+
"for",
36+
"while",
37+
"do",
38+
"try",
39+
"catch",
40+
"case",
41+
"default"
42+
],
43+
"requireDotNotation": true,
44+
"requireLineBreakAfterVariableAssignment": true,
45+
"requireLineFeedAtFileEnd": true,
46+
"requireMultipleVarDecl": true,
47+
"requireNamedUnassignedFunctions": true,
48+
"requireOperatorBeforeLineBreak": [
49+
"?",
50+
"=",
51+
"+",
52+
"-",
53+
"/",
54+
"*",
55+
"==",
56+
"===",
57+
"!=",
58+
"!==",
59+
">",
60+
">=",
61+
"<",
62+
"<="
63+
],
64+
"requirePaddingNewLineAfterVariableDeclaration": true,
65+
"requirePaddingNewLinesAfterUseStrict": true,
66+
"requirePaddingNewLinesBeforeExport": true,
67+
"requirePaddingNewLinesInObjects": true,
68+
"requireParenthesesAroundIIFE": true,
69+
"requireQuotedKeysInObjects": true,
70+
"requireSpaceBetweenArguments": true,
71+
"requireSpacesInAnonymousFunctionExpression": {
72+
"beforeOpeningRoundBrace": true,
73+
"beforeOpeningCurlyBrace": true
74+
},
75+
"requireSpacesInForStatement": true,
76+
"requireSpacesInFunctionDeclaration": {
77+
"beforeOpeningCurlyBrace": true
78+
},
79+
"disallowSpacesInFunctionDeclaration": {
80+
"beforeOpeningRoundBrace": true
81+
},
82+
"requireSpacesInFunctionExpression": {
83+
"beforeOpeningCurlyBrace": true
84+
},
85+
"disallowSpacesInFunctionExpression": {
86+
"beforeOpeningRoundBrace": true
87+
},
88+
"requireSpacesInFunction": {
89+
"beforeOpeningCurlyBrace": true
90+
},
91+
"disallowSpacesInFunction": {
92+
"beforeOpeningRoundBrace": true
93+
},
94+
"requireSpacesInNamedFunctionExpression": {
95+
"beforeOpeningCurlyBrace": true
96+
},
97+
"disallowSpacesInNamedFunctionExpression": {
98+
"beforeOpeningRoundBrace": true
99+
},
100+
"safeContextKeyword": [
101+
"that"
102+
],
103+
"validateAlignedFunctionParameters": {
104+
"lineBreakAfterOpeningBraces": true
105+
}
106+
}

0 commit comments

Comments
 (0)