@siemens/eslint-config-angular 2.0.0-next.1 → 2.0.0-next.3

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.
Files changed (3) hide show
  1. package/README.md +6 -2
  2. package/index.mjs +10 -29
  3. package/package.json +1 -2
package/README.md CHANGED
@@ -40,6 +40,10 @@ will get changed in the patch releases._
40
40
 
41
41
  ### ESLint
42
42
 
43
+ Our ESLint configurations does not include any formatting rules.
44
+ Please use a formatter like [Prettier](https://prettier.io/)
45
+ or add a formatting ruleset for ESLint like [ESLint Stylistic](https://eslint.style/).
46
+
43
47
  #### TypeScript
44
48
 
45
49
  Include the ESLint preset in your root `eslint.config.mjs`:
@@ -87,7 +91,7 @@ const __filename = fileURLToPath(import.meta.url);
87
91
  const __dirname = path.dirname(__filename);
88
92
 
89
93
  export const tsConfig = typescriptEslint.config({
90
- extends: [...angularTypescriptConfig, prettier],
94
+ extends: [...angularTypescriptConfig],
91
95
  files: ['**/*.ts'],
92
96
  languageOptions: {
93
97
  parserOptions: {
@@ -116,7 +120,7 @@ export const tsConfig = typescriptEslint.config({
116
120
  });
117
121
 
118
122
  export const templateConfig = typescriptEslint.config({
119
- extends: [...angularTemplateConfig, prettier],
123
+ extends: [...angularTemplateConfig],
120
124
  files: ['**/*.html']
121
125
  });
122
126
 
package/index.mjs CHANGED
@@ -5,7 +5,6 @@
5
5
  import eslintJs from '@eslint/js';
6
6
  import typescriptEslint from 'typescript-eslint';
7
7
  import angularEslint from 'angular-eslint';
8
- import jsdocPlugin from 'eslint-plugin-jsdoc';
9
8
  import perfectionist from 'eslint-plugin-perfectionist';
10
9
  import preferArrowPlugin from 'eslint-plugin-prefer-arrow';
11
10
 
@@ -18,8 +17,6 @@ export const configBase = typescriptEslint.config({
18
17
  ...angularEslint.configs.tsRecommended
19
18
  ],
20
19
  plugins: {
21
- 'jsdoc': jsdocPlugin,
22
- 'prefer-arrow': preferArrowPlugin,
23
20
  perfectionist
24
21
  },
25
22
  languageOptions: {
@@ -48,13 +45,10 @@ export const configBase = typescriptEslint.config({
48
45
  'space-infix-ops': ['off'],
49
46
  'space-before-blocks': ['off'],
50
47
 
48
+ // Disable the recommended formatting rules.
49
+ 'no-unexpected-multiline': ['off'],
50
+
51
51
  '@typescript-eslint/array-type': ['error'],
52
- '@typescript-eslint/brace-style': ['error', '1tbs', { allowSingleLine: true }],
53
- '@typescript-eslint/comma-dangle': ['error'],
54
- '@typescript-eslint/comma-spacing': ['error'],
55
- '@typescript-eslint/func-call-spacing': ['error'],
56
- '@typescript-eslint/indent': ['error', 2, { SwitchCase: 1 }],
57
- '@typescript-eslint/keyword-spacing': ['error'],
58
52
  '@typescript-eslint/member-ordering': ['off'],
59
53
  '@typescript-eslint/naming-convention': ['off'],
60
54
  '@typescript-eslint/no-non-null-asserted-optional-chain': ['error'],
@@ -66,10 +60,6 @@ export const configBase = typescriptEslint.config({
66
60
  { vars: 'all', args: 'none', ignoreRestSiblings: false }
67
61
  ],
68
62
  '@typescript-eslint/no-var-requires': ['error'],
69
- '@typescript-eslint/space-infix-ops': ['error'],
70
- '@typescript-eslint/space-before-blocks': ['error'],
71
- '@typescript-eslint/type-annotation-spacing': ['error'],
72
- '@typescript-eslint/object-curly-spacing': ['error', 'always'],
73
63
  '@typescript-eslint/no-explicit-any': ['off'],
74
64
  '@typescript-eslint/no-empty-function': ['off'],
75
65
  '@typescript-eslint/no-inferrable-types': ['error', { ignoreParameters: true }],
@@ -80,35 +70,26 @@ export const configBase = typescriptEslint.config({
80
70
  '@typescript-eslint/prefer-function-type': ['error'],
81
71
  '@typescript-eslint/unified-signatures': ['error'],
82
72
 
83
- 'array-bracket-spacing': ['error'],
84
- 'arrow-parens': ['error', 'as-needed'],
85
- 'arrow-spacing': ['error'],
86
- 'block-spacing': ['error'],
87
- 'curly': ['error'],
88
- 'jsdoc/newline-after-description': ['off'],
89
- 'key-spacing': ['error'],
90
73
  'no-duplicate-imports': ['error'],
91
74
  'no-empty': ['error'],
92
75
  'no-irregular-whitespace': ['error'],
93
- 'no-multi-spaces': ['error'],
94
- 'no-multiple-empty-lines': ['error'],
95
- 'prefer-arrow/prefer-arrow-functions': ['off'],
96
- 'quote-props': ['error', 'consistent'],
97
- 'semi-spacing': ['error'],
98
- 'space-in-parens': ['error'],
99
- 'space-unary-ops': ['error'],
100
76
  'sort-imports': ['error', { ignoreCase: true, ignoreDeclarationSort: true }]
101
77
  }
102
78
  });
103
79
 
104
80
  export const configRecommended = typescriptEslint.config({
105
81
  extends: [...angularEslint.configs.tsAll, ...configBase],
82
+ plugins: {
83
+ 'prefer-arrow': preferArrowPlugin
84
+ },
106
85
  rules: {
107
86
  camelcase: ['off'],
108
87
  'no-extra-semi': ['off'],
109
88
  'no-implied-eval': ['off'],
110
89
  'no-loop-func': ['off'],
111
90
  'no-useless-constructor': ['off'],
91
+ 'sort-imports': ['off'],
92
+
112
93
  'perfectionist/sort-imports': [
113
94
  'error',
114
95
  {
@@ -121,6 +102,7 @@ export const configRecommended = typescriptEslint.config({
121
102
  ]
122
103
  }
123
104
  ],
105
+
124
106
  '@angular-eslint/component-max-inline-declarations': ['off'],
125
107
  '@angular-eslint/prefer-on-push-component-change-detection': ['off'],
126
108
  '@angular-eslint/use-component-selector': ['off'],
@@ -171,8 +153,6 @@ export const configRecommended = typescriptEslint.config({
171
153
  format: null
172
154
  }
173
155
  ],
174
-
175
- '@typescript-eslint/no-extra-semi': ['error'],
176
156
  '@typescript-eslint/no-for-in-array': ['error'],
177
157
  '@typescript-eslint/no-implied-eval': ['error'],
178
158
  '@typescript-eslint/no-loop-func': ['error'],
@@ -188,6 +168,7 @@ export const configRecommended = typescriptEslint.config({
188
168
  }
189
169
  ],
190
170
  '@typescript-eslint/prefer-optional-chain': ['error'],
171
+
191
172
  'prefer-arrow/prefer-arrow-functions': ['error']
192
173
  }
193
174
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@siemens/eslint-config-angular",
3
- "version": "2.0.0-next.1",
3
+ "version": "2.0.0-next.3",
4
4
  "description": "Configuration for linting Angular TypeScript and templates using Angular ESLint.",
5
5
  "files": [
6
6
  "*.mjs",
@@ -34,7 +34,6 @@
34
34
  "@eslint/js": "^9.9.1",
35
35
  "angular-eslint": "^18.1.0 || ^19.0.0",
36
36
  "eslint": "^9.9.1",
37
- "eslint-plugin-jsdoc": "^50.2.2",
38
37
  "eslint-plugin-perfectionist": "^4.6.0",
39
38
  "eslint-plugin-prefer-arrow": "^1.2.3",
40
39
  "typescript-eslint": "^8.0.0"