Browse Source

tools: enforce consistent spacing inside braces

PR-URL: https://github.com/nodejs/node/pull/14162
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Refael Ackermann <refack@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
v6
Sebastiaan Deckers 8 years ago
committed by Refael Ackermann
parent
commit
6add5b31fc
No known key found for this signature in database GPG Key ID: CD704BD80FDDDB64
  1. 1
      .eslintignore
  2. 7
      .eslintrc.yaml
  3. 2
      doc/.eslintrc.yaml

1
.eslintignore

@ -5,6 +5,7 @@ test/fixtures
test/disabled test/disabled
test/tmp*/ test/tmp*/
tools/eslint tools/eslint
tools/icu
node_modules node_modules
benchmark/tmp/ benchmark/tmp/
doc/**/*.js doc/**/*.js

7
.eslintrc.yaml

@ -135,6 +135,7 @@ rules:
}] }]
no-tabs: error no-tabs: error
no-trailing-spaces: error no-trailing-spaces: error
object-curly-spacing: [error, always]
one-var-declaration-per-line: error one-var-declaration-per-line: error
operator-linebreak: [error, after] operator-linebreak: [error, after]
quotes: [error, single, avoid-escape] quotes: [error, single, avoid-escape]
@ -142,9 +143,9 @@ rules:
semi-spacing: error semi-spacing: error
space-before-blocks: [error, always] space-before-blocks: [error, always]
space-before-function-paren: [error, { space-before-function-paren: [error, {
"anonymous": "never", anonymous: never,
"named": "never", named: never,
"asyncArrow": "always" asyncArrow: always
}] }]
space-in-parens: [error, never] space-in-parens: [error, never]
space-infix-ops: error space-infix-ops: error

2
doc/.eslintrc.yaml

@ -1,8 +1,6 @@
## Docs-specific linter rules ## Docs-specific linter rules
rules: rules:
object-curly-spacing: [error, always]
# ease some restrictions in doc examples # ease some restrictions in doc examples
no-restricted-properties: off no-restricted-properties: off
no-undef: off no-undef: off

Loading…
Cancel
Save