@luxass/eslint-config 2.0.0 → 2.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@luxass/eslint-config",
3
- "version": "2.0.0",
3
+ "version": "2.1.1",
4
4
  "description": "luxass' ESLint config",
5
5
  "author": {
6
6
  "name": "Lucas Norgaard",
package/src/index.js CHANGED
@@ -6,162 +6,162 @@ module.exports = {
6
6
  },
7
7
  reportUnusedDisableDirectives: true,
8
8
  extends: [
9
- 'eslint-config-standard',
10
- 'plugin:import/recommended',
11
- 'plugin:eslint-comments/recommended',
12
- 'plugin:jsonc/recommended-with-jsonc',
13
- 'plugin:markdown/recommended',
14
- 'plugin:yml/standard',
15
- './javascript',
16
- './typescript'
9
+ "eslint-config-standard",
10
+ "plugin:import/recommended",
11
+ "plugin:eslint-comments/recommended",
12
+ "plugin:jsonc/recommended-with-jsonc",
13
+ "plugin:markdown/recommended",
14
+ "plugin:yml/standard",
15
+ "./javascript",
16
+ "./typescript"
17
17
  ],
18
18
  ignorePatterns: [
19
- '*.min.*',
20
- 'CHANGELOG.md',
21
- 'dist',
22
- 'build',
23
- 'LICENSE*',
24
- 'coverage',
25
- 'public',
26
- 'package-lock.json',
27
- 'pnpm-lock.yaml',
28
- 'yarn.lock',
29
- '!.github',
30
- '!.vscode'
19
+ "*.min.*",
20
+ "CHANGELOG.md",
21
+ "dist",
22
+ "build",
23
+ "LICENSE*",
24
+ "coverage",
25
+ "public",
26
+ "package-lock.json",
27
+ "pnpm-lock.yaml",
28
+ "yarn.lock",
29
+ "!.github",
30
+ "!.vscode"
31
31
  ],
32
- plugins: ['unicorn'],
32
+ plugins: ["unicorn"],
33
33
  settings: {
34
- 'import/resolver': {
35
- node: { extensions: ['.js', '.mjs'] }
34
+ "import/resolver": {
35
+ node: { extensions: [".js", ".mjs"] }
36
36
  }
37
37
  },
38
38
  overrides: [
39
39
  {
40
- files: ['*.json', '*.json5'],
41
- parser: 'jsonc-eslint-parser',
40
+ files: ["*.json", "*.json5"],
41
+ parser: "jsonc-eslint-parser",
42
42
  rules: {
43
- 'jsonc/array-bracket-spacing': ['error', 'never'],
44
- 'jsonc/comma-dangle': ['error', 'never'],
45
- 'jsonc/comma-style': ['error', 'last'],
46
- 'jsonc/indent': ['error', 2],
47
- 'jsonc/key-spacing': ['error', { beforeColon: false, afterColon: true }],
48
- 'jsonc/no-octal-escape': 'error',
49
- 'jsonc/object-curly-newline': ['error', { multiline: true, consistent: true }],
50
- 'jsonc/object-curly-spacing': ['error', 'always'],
51
- 'jsonc/object-property-newline': ['error', { allowMultiplePropertiesPerLine: true }]
43
+ "jsonc/array-bracket-spacing": ["error", "never"],
44
+ "jsonc/comma-dangle": ["error", "never"],
45
+ "jsonc/comma-style": ["error", "last"],
46
+ "jsonc/indent": ["error", 2],
47
+ "jsonc/key-spacing": ["error", { beforeColon: false, afterColon: true }],
48
+ "jsonc/no-octal-escape": "error",
49
+ "jsonc/object-curly-newline": ["error", { multiline: true, consistent: true }],
50
+ "jsonc/object-curly-spacing": ["error", "always"],
51
+ "jsonc/object-property-newline": ["error", { allowMultiplePropertiesPerLine: true }]
52
52
  }
53
53
  },
54
54
  {
55
- files: ['*.yaml', '*.yml'],
56
- parser: 'yaml-eslint-parser',
55
+ files: ["*.yaml", "*.yml"],
56
+ parser: "yaml-eslint-parser",
57
57
  rules: {
58
- 'spaced-comment': 'off'
58
+ "spaced-comment": "off"
59
59
  }
60
60
  },
61
61
  {
62
- files: ['package.json'],
63
- parser: 'jsonc-eslint-parser',
62
+ files: ["package.json"],
63
+ parser: "jsonc-eslint-parser",
64
64
  rules: {
65
- 'jsonc/sort-keys': [
66
- 'error',
65
+ "jsonc/sort-keys": [
66
+ "error",
67
67
  {
68
- pathPattern: '^$',
68
+ pathPattern: "^$",
69
69
  order: [
70
- 'name',
71
- 'publisher',
72
- 'displayName',
73
- 'version',
74
- 'private',
75
- 'type',
76
- 'packageManager',
77
- 'description',
78
- 'author',
79
- 'license',
80
- 'funding',
81
- 'homepage',
82
- 'repository',
83
- 'bugs',
84
- 'keywords',
85
- 'categories',
86
- 'sideEffects',
87
- 'exports',
88
- 'main',
89
- 'module',
90
- 'types',
91
- 'typesVersions',
92
- 'bin',
93
- 'icon',
94
- 'files',
95
- 'engines',
96
- 'activationEvents',
97
- 'contributes',
98
- 'scripts',
99
- 'peerDependencies',
100
- 'peerDependenciesMeta',
101
- 'dependencies',
102
- 'optionalDependencies',
103
- 'devDependencies',
104
- 'pnpm'
70
+ "name",
71
+ "publisher",
72
+ "displayName",
73
+ "version",
74
+ "private",
75
+ "type",
76
+ "packageManager",
77
+ "description",
78
+ "author",
79
+ "license",
80
+ "funding",
81
+ "homepage",
82
+ "repository",
83
+ "bugs",
84
+ "keywords",
85
+ "categories",
86
+ "sideEffects",
87
+ "exports",
88
+ "main",
89
+ "module",
90
+ "types",
91
+ "typesVersions",
92
+ "bin",
93
+ "icon",
94
+ "files",
95
+ "engines",
96
+ "activationEvents",
97
+ "contributes",
98
+ "scripts",
99
+ "peerDependencies",
100
+ "peerDependenciesMeta",
101
+ "dependencies",
102
+ "optionalDependencies",
103
+ "devDependencies",
104
+ "pnpm"
105
105
  ]
106
106
  },
107
107
  {
108
- pathPattern: '^(?:dev|peer|optional|bundled)?[Dd]ependencies$',
109
- order: { type: 'asc' }
108
+ pathPattern: "^(?:dev|peer|optional|bundled)?[Dd]ependencies$",
109
+ order: { type: "asc" }
110
110
  },
111
111
  {
112
- pathPattern: '^exports.*$',
113
- order: ['types', 'require', 'import']
112
+ pathPattern: "^exports.*$",
113
+ order: ["types", "require", "import"]
114
114
  }
115
115
  ]
116
116
  }
117
117
  },
118
118
  {
119
- files: ['*.d.ts'],
119
+ files: ["*.d.ts"],
120
120
  rules: {
121
- 'import/no-duplicates': 'off'
121
+ "import/no-duplicates": "off"
122
122
  }
123
123
  },
124
124
  {
125
- files: ['*.js'],
125
+ files: ["*.js"],
126
126
  rules: {
127
- '@typescript-eslint/no-var-requires': 'off'
127
+ "@typescript-eslint/no-var-requires": "off"
128
128
  }
129
129
  },
130
130
  {
131
- files: ['scripts/**/*.*', 'cli.*'],
131
+ files: ["scripts/**/*.*", "cli.*"],
132
132
  rules: {
133
- 'no-console': 'off'
133
+ "no-console": "off"
134
134
  }
135
135
  },
136
136
  {
137
- files: ['*.test.ts', '*.test.js', '*.spec.ts', '*.spec.js'],
137
+ files: ["*.test.ts", "*.test.js", "*.spec.ts", "*.spec.js"],
138
138
  rules: {
139
- 'no-unused-expressions': 'off'
139
+ "no-unused-expressions": "off"
140
140
  }
141
141
  },
142
142
  {
143
- files: ['**/*.md/*.*'],
143
+ files: ["**/*.md/*.*"],
144
144
  rules: {
145
- '@typescript-eslint/no-redeclare': 'off',
146
- '@typescript-eslint/no-unused-vars': 'off',
147
- '@typescript-eslint/no-use-before-define': 'off',
148
- '@typescript-eslint/no-var-requires': 'off',
149
- '@typescript-eslint/comma-dangle': 'off',
150
- 'import/no-unresolved': 'off',
151
- 'no-alert': 'off',
152
- 'no-console': 'off',
153
- 'no-restricted-imports': 'off',
154
- 'no-undef': 'off',
155
- 'no-unused-expressions': 'off',
156
- 'no-unused-vars': 'off'
145
+ "@typescript-eslint/no-redeclare": "off",
146
+ "@typescript-eslint/no-unused-vars": "off",
147
+ "@typescript-eslint/no-use-before-define": "off",
148
+ "@typescript-eslint/no-var-requires": "off",
149
+ "@typescript-eslint/comma-dangle": "off",
150
+ "import/no-unresolved": "off",
151
+ "no-alert": "off",
152
+ "no-console": "off",
153
+ "no-restricted-imports": "off",
154
+ "no-undef": "off",
155
+ "no-unused-expressions": "off",
156
+ "no-unused-vars": "off"
157
157
  }
158
158
  }
159
159
  ],
160
160
  rules: {
161
- 'eol-last': 'off',
162
- 'no-trailing-spaces': 'off',
163
- 'padded-blocks': 'off',
164
- 'yml/quotes': ['error', { prefer: 'single', avoidEscape: false }],
165
- 'yml/no-empty-document': 'off'
161
+ "eol-last": "off",
162
+ "no-trailing-spaces": "off",
163
+ "padded-blocks": "off",
164
+ "yml/quotes": ["error", { prefer: "single", avoidEscape: false }],
165
+ "yml/no-empty-document": "off"
166
166
  }
167
167
  };
package/src/typescript.js CHANGED
@@ -17,7 +17,10 @@ module.exports = {
17
17
  "@typescript-eslint/ban-ts-comment": ["error", { "ts-ignore": "allow-with-description" }],
18
18
  "@typescript-eslint/member-delimiter-style": "warn",
19
19
  "@typescript-eslint/type-annotation-spacing": ["error", {}],
20
- "@typescript-eslint/consistent-type-imports": "warn",
20
+ "@typescript-eslint/consistent-type-imports": ["warn", {
21
+ prefer: "type-imports",
22
+ disallowTypeAnnotations: false
23
+ }],
21
24
  "no-useless-constructor": "off",
22
25
  indent: "off",
23
26
  "@typescript-eslint/indent": [