File: .eslintrc.yml

package info (click to toggle)
node-nock 13.5.4-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 2,168 kB
  • sloc: javascript: 12,018; makefile: 11
file content (49 lines) | stat: -rw-r--r-- 1,121 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
env:
  node: true

parserOptions:
  ecmaVersion: 9
  # Override eslint-config-standard, which incorrectly sets this to "module",
  # though that setting is only for ES6 modules, not CommonJS modules.
  sourceType: 'script'

extends:
  - 'eslint:recommended'
  - standard
  - prettier

plugins:
  - mocha

overrides:
  - files:
      - 'tests/**/*.js'
    env:
      mocha: true
    rules:
      mocha/no-exclusive-tests: 'error'

rules:
  # TODO These are included in standard and should be cleaned up and turned on.
  n/no-deprecated-api: 'off' # we still make heavy use of url.parse

  # TODO remove once we drop support for Node 10
  node/no-deprecated-api: 'off'

  # Nock additions.
  strict: ['error', 'safe']
  no-console: 'error'
  no-loop-func: 'error'
  no-var: 'error'
  prefer-const: 'error'
  object-shorthand: ['error', 'properties']
  prefer-template: 'error'
  arrow-body-style: ['error', 'as-needed']
  prefer-destructuring:
    [
      'error',
      {
        'VariableDeclarator': { 'array': false, 'object': true },
        'AssignmentExpression': { 'array': false, 'object': false },
      },
    ]