Skip to content

Commit 258ee4b

Browse files
Trotttargos
authored andcommitted
tools: enable ESLint recommended configuration
PR-URL: #41463 Reviewed-By: Tobias Nießen <[email protected]> Reviewed-By: Michaël Zasso <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Geoffrey Booth <[email protected]>
1 parent 090a674 commit 258ee4b

File tree

1 file changed

+8
-51
lines changed

1 file changed

+8
-51
lines changed

.eslintrc.js

+8-51
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ Module._findPath = (request, paths, isMain) => {
3535

3636
module.exports = {
3737
root: true,
38-
extends: ['plugin:jsdoc/recommended'],
38+
extends: ['eslint:recommended', 'plugin:jsdoc/recommended'],
3939
plugins: ['jsdoc', 'markdown', 'node-core'],
4040
parser: '@babel/eslint-parser',
4141
parserOptions: {
@@ -142,17 +142,14 @@ module.exports = {
142142
'comma-spacing': 'error',
143143
'comma-style': 'error',
144144
'computed-property-spacing': 'error',
145-
'constructor-super': 'error',
146145
'default-case-last': 'error',
147146
'dot-location': ['error', 'property'],
148147
'dot-notation': 'error',
149148
'eol-last': 'error',
150149
'eqeqeq': ['error', 'smart'],
151-
'for-direction': 'error',
152150
'func-call-spacing': 'error',
153151
'func-name-matching': 'error',
154152
'func-style': ['error', 'declaration', { allowArrowFunctions: true }],
155-
'getter-return': 'error',
156153
'indent': ['error', 2, {
157154
ArrayExpression: 'first',
158155
CallExpression: { arguments: 'first' },
@@ -174,49 +171,20 @@ module.exports = {
174171
tabWidth: 2,
175172
}],
176173
'new-parens': 'error',
177-
'no-async-promise-executor': 'error',
178-
'no-case-declarations': 'error',
179-
'no-class-assign': 'error',
180174
'no-confusing-arrow': 'error',
181-
'no-const-assign': 'error',
182175
'no-constant-condition': ['error', { checkLoops: false }],
183176
'no-constructor-return': 'error',
184-
'no-control-regex': 'error',
185-
'no-debugger': 'error',
186-
'no-delete-var': 'error',
187-
'no-dupe-args': 'error',
188-
'no-dupe-class-members': 'error',
189-
'no-dupe-keys': 'error',
190-
'no-dupe-else-if': 'error',
191-
'no-duplicate-case': 'error',
192177
'no-duplicate-imports': 'error',
193178
'no-else-return': ['error', { allowElseIf: true }],
194-
'no-empty-character-class': 'error',
195-
'no-ex-assign': 'error',
196-
'no-extra-boolean-cast': 'error',
197179
'no-extra-parens': ['error', 'functions'],
198-
'no-extra-semi': 'error',
199-
'no-fallthrough': 'error',
200-
'no-func-assign': 'error',
201-
'no-global-assign': 'error',
202-
'no-invalid-regexp': 'error',
203-
'no-irregular-whitespace': 'error',
204180
'no-lonely-if': 'error',
205-
'no-loss-of-precision': 'error',
206-
'no-misleading-character-class': 'error',
207181
'no-mixed-requires': 'error',
208-
'no-mixed-spaces-and-tabs': 'error',
209182
'no-multi-spaces': ['error', { ignoreEOLComments: true }],
210183
'no-multiple-empty-lines': ['error', { max: 2, maxEOF: 0, maxBOF: 0 }],
211184
'no-new-require': 'error',
212-
'no-new-symbol': 'error',
213-
'no-nonoctal-decimal-escape': 'error',
214-
'no-obj-calls': 'error',
215-
'no-octal': 'error',
216185
'no-path-concat': 'error',
217186
'no-proto': 'error',
218187
'no-redeclare': ['error', { 'builtinGlobals': false }],
219-
'no-regex-spaces': 'error',
220188
'no-restricted-modules': ['error', 'sys'],
221189
/* eslint-disable max-len */
222190
'no-restricted-properties': [
@@ -273,41 +241,26 @@ module.exports = {
273241
],
274242
/* eslint-enable max-len */
275243
'no-return-await': 'error',
276-
'no-self-assign': 'error',
277244
'no-self-compare': 'error',
278-
'no-setter-return': 'error',
279-
'no-shadow-restricted-names': 'error',
280-
'no-sparse-arrays': 'error',
281245
'no-tabs': 'error',
282246
'no-template-curly-in-string': 'error',
283-
'no-this-before-super': 'error',
284247
'no-throw-literal': 'error',
285248
'no-trailing-spaces': 'error',
286249
'no-undef': ['error', { typeof: true }],
287250
'no-undef-init': 'error',
288-
'no-unexpected-multiline': 'error',
289-
'no-unreachable': 'error',
290-
'no-unsafe-finally': 'error',
291-
'no-unsafe-negation': 'error',
292-
'no-unsafe-optional-chaining': 'error',
293251
'no-unused-expressions': ['error', { allowShortCircuit: true }],
294-
'no-unused-labels': 'error',
295252
'no-unused-vars': ['error', { args: 'none', caughtErrors: 'all' }],
296253
'no-use-before-define': ['error', {
297254
classes: true,
298255
functions: false,
299256
variables: false,
300257
}],
301-
'no-useless-backreference': 'error',
302258
'no-useless-call': 'error',
303-
'no-useless-catch': 'error',
304259
'no-useless-concat': 'error',
305260
'no-useless-constructor': 'error',
306-
'no-useless-escape': 'error',
307261
'no-useless-return': 'error',
308262
'no-void': 'error',
309263
'no-whitespace-before-property': 'error',
310-
'no-with': 'error',
311264
'object-curly-newline': 'error',
312265
'object-curly-spacing': ['error', 'always'],
313266
'one-var': ['error', { initialized: 'never' }],
@@ -322,7 +275,6 @@ module.exports = {
322275
'quotes': ['error', 'single', { avoidEscape: true }],
323276
'quote-props': ['error', 'consistent'],
324277
'rest-spread-spacing': 'error',
325-
'require-yield': 'error',
326278
'semi': 'error',
327279
'semi-spacing': 'error',
328280
'space-before-blocks': ['error', 'always'],
@@ -342,10 +294,15 @@ module.exports = {
342294
'symbol-description': 'error',
343295
'template-curly-spacing': 'error',
344296
'unicode-bom': 'error',
345-
'use-isnan': 'error',
346297
'valid-typeof': ['error', { requireStringLiterals: true }],
347298

348-
// JSDoc rules
299+
// ESLint recommended rules that we disable
300+
'no-cond-assign': 'off',
301+
'no-empty': 'off',
302+
'no-inner-declarations': 'off',
303+
'no-prototype-builtins': 'off',
304+
305+
// JSDoc recommended rules that we disable
349306
'jsdoc/require-jsdoc': 'off',
350307
'jsdoc/require-param-description': 'off',
351308
'jsdoc/newline-after-description': 'off',

0 commit comments

Comments
 (0)