@angular-eslint/eslint-plugin 19.8.1-alpha.1 → 19.8.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/README.md CHANGED
@@ -43,12 +43,12 @@ Please see https://github.com/angular-eslint/angular-eslint for full usage instr
43
43
  <!-- prettier-ignore-start -->
44
44
  | Rule | Description | :white_check_mark: | :wrench: | :bulb: |
45
45
  | --- | --- | --- | --- | --- |
46
- | [`component-class-suffix`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/component-class-suffix.md) | Classes decorated with @Component must have suffix "Component" (or custom) in their name. Note: As of v20, this is no longer recommended by the Angular Team. | | | |
46
+ | [`component-class-suffix`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/component-class-suffix.md) | Classes decorated with @Component must have suffix "Component" (or custom) in their name. See more at https://angular.dev/style-guide#style-02-03 | :white_check_mark: | | |
47
47
  | [`component-max-inline-declarations`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/component-max-inline-declarations.md) | Enforces a maximum number of lines in inline template, styles and animations. See more at https://angular.dev/style-guide#style-05-04 | | | |
48
48
  | [`component-selector`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/component-selector.md) | Component selectors should follow given naming rules. See more at https://angular.dev/style-guide#style-02-07, https://angular.dev/style-guide#style-05-02 and https://angular.dev/style-guide#style-05-03. | | | |
49
49
  | [`consistent-component-styles`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/consistent-component-styles.md) | Ensures consistent usage of `styles`/`styleUrls`/`styleUrl` within Component metadata | | :wrench: | |
50
50
  | [`contextual-decorator`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/contextual-decorator.md) | Ensures that classes use contextual decorators in its body | | | |
51
- | [`directive-class-suffix`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/directive-class-suffix.md) | Classes decorated with @Directive must have suffix "Directive" (or custom) in their name. Note: As of v20, this is no longer recommended by the Angular Team. | | | |
51
+ | [`directive-class-suffix`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/directive-class-suffix.md) | Classes decorated with @Directive must have suffix "Directive" (or custom) in their name. See more at https://angular.dev/style-guide#style-02-03 | :white_check_mark: | | |
52
52
  | [`directive-selector`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/directive-selector.md) | Directive selectors should follow given naming rules. See more at https://angular.dev/style-guide#style-02-06 and https://angular.dev/style-guide#style-02-08. | | | |
53
53
  | [`no-conflicting-lifecycle`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/no-conflicting-lifecycle.md) | Ensures that directives not implement conflicting lifecycle interfaces. | | | |
54
54
  | [`no-duplicates-in-metadata-arrays`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/no-duplicates-in-metadata-arrays.md) | Ensures that metadata arrays do not contain duplicate entries. | | | |
@@ -66,12 +66,12 @@ Please see https://github.com/angular-eslint/angular-eslint for full usage instr
66
66
  | [`no-queries-metadata-property`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/no-queries-metadata-property.md) | Disallows usage of the `queries` metadata property. See more at https://angular.dev/style-guide#style-05-12. | | | |
67
67
  | [`no-uncalled-signals`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/no-uncalled-signals.md) | Warns user about unintentionally doing logic on the signal, rather than the signal's value | | | :bulb: |
68
68
  | [`pipe-prefix`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/pipe-prefix.md) | Enforce consistent prefix for pipes. | | | |
69
- | [`prefer-inject`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/prefer-inject.md) | Prefer using the inject() function over constructor parameter injection | :white_check_mark: | | |
69
+ | [`prefer-inject`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/prefer-inject.md) | Prefer using the inject() function over constructor parameter injection | | | |
70
70
  | [`prefer-on-push-component-change-detection`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/prefer-on-push-component-change-detection.md) | Ensures component's `changeDetection` is set to `ChangeDetectionStrategy.OnPush` | | | :bulb: |
71
71
  | [`prefer-output-emitter-ref`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/prefer-output-emitter-ref.md) | Use `OutputEmitterRef` instead of `@Output()` | | | |
72
72
  | [`prefer-output-readonly`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/prefer-output-readonly.md) | Prefer to declare `@Output`, `OutputEmitterRef` and `OutputRef` as `readonly` since they are not supposed to be reassigned | | | :bulb: |
73
73
  | [`prefer-signals`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/prefer-signals.md) | Use readonly signals instead of `@Input()`, `@ViewChild()` and other legacy decorators | | :wrench: | |
74
- | [`prefer-standalone`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/prefer-standalone.md) | Ensures Components, Directives and Pipes do not opt out of standalone. | :white_check_mark: | | :bulb: |
74
+ | [`prefer-standalone`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/prefer-standalone.md) | Ensures Components, Directives and Pipes do not opt out of standalone | :white_check_mark: | :wrench: | |
75
75
  | [`relative-url-prefix`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/relative-url-prefix.md) | The ./ and ../ prefix is standard syntax for relative URLs; don't depend on Angular's current ability to do without that prefix. See more at https://angular.dev/style-guide#style-05-04 | | | |
76
76
  | [`require-localize-metadata`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/require-localize-metadata.md) | Ensures that $localize tagged messages contain helpful metadata to aid with translations. | | | |
77
77
  | [`runtime-localize`](https://github.com/angular-eslint/angular-eslint/blob/main/packages/eslint-plugin/docs/rules/runtime-localize.md) | Ensures that $localize tagged messages can use runtime-loaded translations. | | | |
@@ -2,7 +2,9 @@
2
2
  "parser": "@typescript-eslint/parser",
3
3
  "plugins": ["@angular-eslint"],
4
4
  "rules": {
5
+ "@angular-eslint/component-class-suffix": "error",
5
6
  "@angular-eslint/contextual-lifecycle": "error",
7
+ "@angular-eslint/directive-class-suffix": "error",
6
8
  "@angular-eslint/no-empty-lifecycle-method": "error",
7
9
  "@angular-eslint/no-input-rename": "error",
8
10
  "@angular-eslint/no-inputs-metadata-property": "error",
@@ -10,7 +12,6 @@
10
12
  "@angular-eslint/no-output-on-prefix": "error",
11
13
  "@angular-eslint/no-output-rename": "error",
12
14
  "@angular-eslint/no-outputs-metadata-property": "error",
13
- "@angular-eslint/prefer-inject": "error",
14
15
  "@angular-eslint/prefer-standalone": "error",
15
16
  "@angular-eslint/use-pipe-transform-interface": "error",
16
17
  "@angular-eslint/use-lifecycle-interface": "warn"
package/dist/index.d.ts CHANGED
@@ -53,7 +53,9 @@ declare const _default: {
53
53
  parser: string;
54
54
  plugins: string[];
55
55
  rules: {
56
+ "@angular-eslint/component-class-suffix": string;
56
57
  "@angular-eslint/contextual-lifecycle": string;
58
+ "@angular-eslint/directive-class-suffix": string;
57
59
  "@angular-eslint/no-empty-lifecycle-method": string;
58
60
  "@angular-eslint/no-input-rename": string;
59
61
  "@angular-eslint/no-inputs-metadata-property": string;
@@ -61,7 +63,6 @@ declare const _default: {
61
63
  "@angular-eslint/no-output-on-prefix": string;
62
64
  "@angular-eslint/no-output-rename": string;
63
65
  "@angular-eslint/no-outputs-metadata-property": string;
64
- "@angular-eslint/prefer-inject": string;
65
66
  "@angular-eslint/prefer-standalone": string;
66
67
  "@angular-eslint/use-pipe-transform-interface": string;
67
68
  "@angular-eslint/use-lifecycle-interface": string;
@@ -103,7 +104,7 @@ declare const _default: {
103
104
  useTypeChecking: boolean;
104
105
  additionalSignalCreationFunctions: string[];
105
106
  }], import("./utils/create-eslint-rule").RuleDocs, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
106
- "prefer-standalone": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/prefer-standalone").MessageIds, [], import("./utils/create-eslint-rule").RuleDocs, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
107
+ "prefer-standalone": import("@typescript-eslint/utils/ts-eslint").RuleModule<"preferStandalone", [], import("./utils/create-eslint-rule").RuleDocs, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
107
108
  "prefer-inject": import("@typescript-eslint/utils/ts-eslint").RuleModule<"preferInject", [], import("./utils/create-eslint-rule").RuleDocs, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
108
109
  "prefer-output-emitter-ref": import("@typescript-eslint/utils/ts-eslint").RuleModule<"preferOutputEmitterRef", [], import("./utils/create-eslint-rule").RuleDocs, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
109
110
  "prefer-output-readonly": import("@typescript-eslint/utils/ts-eslint").RuleModule<import("./rules/prefer-output-readonly").MessageIds, [], import("./utils/create-eslint-rule").RuleDocs, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqIA,kBAmDE"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqIA,kBAmDE"}
@@ -1 +1 @@
1
- {"version":3,"file":"component-class-suffix.d.ts","sourceRoot":"","sources":["../../src/rules/component-class-suffix.ts"],"names":[],"mappings":"AAQA,MAAM,MAAM,OAAO,GAAG;IACpB;QACE,QAAQ,EAAE,MAAM,EAAE,CAAC;KACpB;CACF,CAAC;AACF,MAAM,MAAM,UAAU,GAAG,sBAAsB,CAAC;AAChD,eAAO,MAAM,SAAS,2BAA2B,CAAC;;AAElD,wBAiDG"}
1
+ {"version":3,"file":"component-class-suffix.d.ts","sourceRoot":"","sources":["../../src/rules/component-class-suffix.ts"],"names":[],"mappings":"AAQA,MAAM,MAAM,OAAO,GAAG;IACpB;QACE,QAAQ,EAAE,MAAM,EAAE,CAAC;KACpB;CACF,CAAC;AACF,MAAM,MAAM,UAAU,GAAG,sBAAsB,CAAC;AAChD,eAAO,MAAM,SAAS,2BAA2B,CAAC;;AAGlD,wBAkDG"}
@@ -4,12 +4,14 @@ exports.RULE_NAME = void 0;
4
4
  const utils_1 = require("@angular-eslint/utils");
5
5
  const create_eslint_rule_1 = require("../utils/create-eslint-rule");
6
6
  exports.RULE_NAME = 'component-class-suffix';
7
+ const STYLE_GUIDE_LINK = 'https://angular.dev/style-guide#style-02-03';
7
8
  exports.default = (0, create_eslint_rule_1.createESLintRule)({
8
9
  name: exports.RULE_NAME,
9
10
  meta: {
10
11
  type: 'suggestion',
11
12
  docs: {
12
- description: `Classes decorated with @Component must have suffix "Component" (or custom) in their name. Note: As of v20, this is no longer recommended by the Angular Team.`,
13
+ description: `Classes decorated with @Component must have suffix "Component" (or custom) in their name. See more at ${STYLE_GUIDE_LINK}`,
14
+ recommended: 'recommended',
13
15
  },
14
16
  schema: [
15
17
  {
@@ -26,7 +28,7 @@ exports.default = (0, create_eslint_rule_1.createESLintRule)({
26
28
  },
27
29
  ],
28
30
  messages: {
29
- componentClassSuffix: `Component class names should end with one of these suffixes: {{suffixes}}`,
31
+ componentClassSuffix: `Component class names should end with one of these suffixes: {{suffixes}} (${STYLE_GUIDE_LINK})`,
30
32
  },
31
33
  },
32
34
  defaultOptions: [
@@ -1 +1 @@
1
- {"version":3,"file":"directive-class-suffix.d.ts","sourceRoot":"","sources":["../../src/rules/directive-class-suffix.ts"],"names":[],"mappings":"AAQA,MAAM,MAAM,OAAO,GAAG,CAAC;IAAE,QAAQ,CAAC,QAAQ,EAAE,SAAS,MAAM,EAAE,CAAA;CAAE,CAAC,CAAC;AACjE,MAAM,MAAM,UAAU,GAAG,sBAAsB,CAAC;AAChD,eAAO,MAAM,SAAS,2BAA2B,CAAC;;AAIlD,wBA4DG"}
1
+ {"version":3,"file":"directive-class-suffix.d.ts","sourceRoot":"","sources":["../../src/rules/directive-class-suffix.ts"],"names":[],"mappings":"AAQA,MAAM,MAAM,OAAO,GAAG,CAAC;IAAE,QAAQ,CAAC,QAAQ,EAAE,SAAS,MAAM,EAAE,CAAA;CAAE,CAAC,CAAC;AACjE,MAAM,MAAM,UAAU,GAAG,sBAAsB,CAAC;AAChD,eAAO,MAAM,SAAS,2BAA2B,CAAC;;AAKlD,wBA6DG"}
@@ -4,6 +4,7 @@ exports.RULE_NAME = void 0;
4
4
  const utils_1 = require("@angular-eslint/utils");
5
5
  const create_eslint_rule_1 = require("../utils/create-eslint-rule");
6
6
  exports.RULE_NAME = 'directive-class-suffix';
7
+ const STYLE_GUIDE_LINK = 'https://angular.dev/style-guide#style-02-03';
7
8
  const DEFAULT_SUFFIXES = ['Directive'];
8
9
  const VALIDATOR_SUFFIX = 'Validator';
9
10
  exports.default = (0, create_eslint_rule_1.createESLintRule)({
@@ -11,7 +12,8 @@ exports.default = (0, create_eslint_rule_1.createESLintRule)({
11
12
  meta: {
12
13
  type: 'suggestion',
13
14
  docs: {
14
- description: `Classes decorated with @Directive must have suffix "Directive" (or custom) in their name. Note: As of v20, this is no longer recommended by the Angular Team.`,
15
+ description: `Classes decorated with @Directive must have suffix "Directive" (or custom) in their name. See more at ${STYLE_GUIDE_LINK}`,
16
+ recommended: 'recommended',
15
17
  },
16
18
  schema: [
17
19
  {
@@ -28,7 +30,7 @@ exports.default = (0, create_eslint_rule_1.createESLintRule)({
28
30
  },
29
31
  ],
30
32
  messages: {
31
- directiveClassSuffix: `Directive class names should end with one of these suffixes: {{suffixes}}`,
33
+ directiveClassSuffix: `Directive class names should end with one of these suffixes: {{suffixes}} (${STYLE_GUIDE_LINK})`,
32
34
  },
33
35
  },
34
36
  defaultOptions: [{ suffixes: DEFAULT_SUFFIXES }],
@@ -1 +1 @@
1
- {"version":3,"file":"prefer-inject.d.ts","sourceRoot":"","sources":["../../src/rules/prefer-inject.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,OAAO,GAAG,EAAE,CAAC;AAEzB,MAAM,MAAM,UAAU,GAAG,cAAc,CAAC;AACxC,eAAO,MAAM,SAAS,kBAAkB,CAAC;;AAEzC,wBAkGG"}
1
+ {"version":3,"file":"prefer-inject.d.ts","sourceRoot":"","sources":["../../src/rules/prefer-inject.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,OAAO,GAAG,EAAE,CAAC;AAEzB,MAAM,MAAM,UAAU,GAAG,cAAc,CAAC;AACxC,eAAO,MAAM,SAAS,kBAAkB,CAAC;;AAEzC,wBAiGG"}
@@ -11,7 +11,6 @@ exports.default = (0, create_eslint_rule_1.createESLintRule)({
11
11
  type: 'suggestion',
12
12
  docs: {
13
13
  description: 'Prefer using the inject() function over constructor parameter injection',
14
- recommended: 'recommended',
15
14
  },
16
15
  schema: [],
17
16
  messages: {
@@ -1,6 +1,6 @@
1
1
  export type Options = [];
2
- export type MessageIds = 'preferStandalone' | 'removeStandaloneFalse';
2
+ export type MessageIds = 'preferStandalone';
3
3
  export declare const RULE_NAME = "prefer-standalone";
4
- declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<MessageIds, [], import("../utils/create-eslint-rule").RuleDocs, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
4
+ declare const _default: import("@typescript-eslint/utils/ts-eslint").RuleModule<"preferStandalone", [], import("../utils/create-eslint-rule").RuleDocs, import("@typescript-eslint/utils/ts-eslint").RuleListener>;
5
5
  export default _default;
6
6
  //# sourceMappingURL=prefer-standalone.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"prefer-standalone.d.ts","sourceRoot":"","sources":["../../src/rules/prefer-standalone.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,OAAO,GAAG,EAAE,CAAC;AAEzB,MAAM,MAAM,UAAU,GAAG,kBAAkB,GAAG,uBAAuB,CAAC;AACtE,eAAO,MAAM,SAAS,sBAAsB,CAAC;;AAK7C,wBAkEG"}
1
+ {"version":3,"file":"prefer-standalone.d.ts","sourceRoot":"","sources":["../../src/rules/prefer-standalone.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,OAAO,GAAG,EAAE,CAAC;AAEzB,MAAM,MAAM,UAAU,GAAG,kBAAkB,CAAC;AAC5C,eAAO,MAAM,SAAS,sBAAsB,CAAC;;AAE7C,wBA4DG"}
@@ -4,20 +4,18 @@ exports.RULE_NAME = void 0;
4
4
  const utils_1 = require("@angular-eslint/utils");
5
5
  const create_eslint_rule_1 = require("../utils/create-eslint-rule");
6
6
  exports.RULE_NAME = 'prefer-standalone';
7
- const RECOMMENDED_GUIDE_URL = 'https://angular.dev/reference/migrations/standalone';
8
7
  exports.default = (0, create_eslint_rule_1.createESLintRule)({
9
8
  name: exports.RULE_NAME,
10
9
  meta: {
11
10
  type: 'suggestion',
12
11
  docs: {
13
- description: `Ensures Components, Directives and Pipes do not opt out of standalone.`,
12
+ description: `Ensures Components, Directives and Pipes do not opt out of standalone`,
14
13
  recommended: 'recommended',
15
14
  },
16
- hasSuggestions: true,
15
+ fixable: 'code',
17
16
  schema: [],
18
17
  messages: {
19
- preferStandalone: `Components, Directives and Pipes should not opt out of standalone. Following this guide is highly recommended: ${RECOMMENDED_GUIDE_URL}`,
20
- removeStandaloneFalse: `Quickly remove 'standalone: false'. NOTE - Following this guide is highly recommended: ${RECOMMENDED_GUIDE_URL}`,
18
+ preferStandalone: `Components, Directives and Pipes should not opt out of standalone`,
21
19
  },
22
20
  },
23
21
  defaultOptions: [],
@@ -36,22 +34,17 @@ exports.default = (0, create_eslint_rule_1.createESLintRule)({
36
34
  node: standalone.parent,
37
35
  messageId: 'preferStandalone',
38
36
  data: { type },
39
- suggest: [
40
- {
41
- messageId: 'removeStandaloneFalse',
42
- fix: (fixer) => {
43
- // Remove the standalone property altogether if it was set to false
44
- const tokenAfter = context.sourceCode.getTokenAfter(standalone.parent);
45
- // Remove the trailing comma, if present
46
- const removeStart = standalone.parent.range[0];
47
- let removeEnd = standalone.parent.range[1];
48
- if (tokenAfter && tokenAfter.value === ',') {
49
- removeEnd = tokenAfter.range[1];
50
- }
51
- return fixer.removeRange([removeStart, removeEnd]);
52
- },
53
- },
54
- ],
37
+ fix: (fixer) => {
38
+ // Remove the standalone property altogether if it was set to false
39
+ const tokenAfter = context.sourceCode.getTokenAfter(standalone.parent);
40
+ // Remove the trailing comma, if present
41
+ const removeStart = standalone.parent.range[0];
42
+ let removeEnd = standalone.parent.range[1];
43
+ if (tokenAfter && tokenAfter.value === ',') {
44
+ removeEnd = tokenAfter.range[1];
45
+ }
46
+ return fixer.removeRange([removeStart, removeEnd]);
47
+ },
55
48
  });
56
49
  };
57
50
  return {
@@ -1 +1 @@
1
- {"version":3,"file":"sort-keys-in-type-decorator.d.ts","sourceRoot":"","sources":["../../src/rules/sort-keys-in-type-decorator.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAY,MAAM,0BAA0B,CAAC;AAG9D,MAAM,MAAM,OAAO,GAAG;IACpB;QACE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;KACzB;CACF,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG,gBAAgB,CAAC;AA2D1C,eAAO,MAAM,SAAS,gCAAgC,CAAC;;AAEvD,wBA+IG"}
1
+ {"version":3,"file":"sort-keys-in-type-decorator.d.ts","sourceRoot":"","sources":["../../src/rules/sort-keys-in-type-decorator.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAY,MAAM,0BAA0B,CAAC;AAG9D,MAAM,MAAM,OAAO,GAAG;IACpB;QACE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;KACzB;CACF,CAAC;AAEF,MAAM,MAAM,UAAU,GAAG,gBAAgB,CAAC;AAoB1C,eAAO,MAAM,SAAS,gCAAgC,CAAC;;AAEvD,wBA+IG"}
@@ -4,7 +4,6 @@ exports.RULE_NAME = void 0;
4
4
  const utils_1 = require("@angular-eslint/utils");
5
5
  const create_eslint_rule_1 = require("../utils/create-eslint-rule");
6
6
  const DEFAULT_ORDER = {
7
- // https://angular.dev/api/core/Component
8
7
  Component: [
9
8
  'selector',
10
9
  'imports',
@@ -14,50 +13,12 @@ const DEFAULT_ORDER = {
14
13
  'styleUrl',
15
14
  'styleUrls',
16
15
  'styles',
17
- 'providers',
18
- 'changeDetection',
19
16
  'encapsulation',
20
- 'viewProviders',
21
- 'host',
22
- 'hostDirectives',
23
- 'inputs',
24
- 'outputs',
25
- 'animations',
26
- 'schemas',
27
- 'exportAs',
28
- 'queries',
29
- 'preserveWhitespaces',
30
- 'jit',
31
- // Deprecated properties according to https://angular.dev/api/core/Component
32
- 'moduleId',
33
- 'interpolation',
34
- ],
35
- // https://angular.dev/api/core/Directive
36
- Directive: [
37
- 'selector',
38
- 'standalone',
39
- 'providers',
40
- 'host',
41
- 'hostDirectives',
42
- 'inputs',
43
- 'outputs',
44
- 'exportAs',
45
- 'queries',
46
- 'jit',
47
- ],
48
- // https://angular.dev/api/core/NgModule
49
- NgModule: [
50
- 'id', // rarely used but good to have first if set
51
- 'imports',
52
- 'declarations',
53
- 'providers',
54
- 'exports',
55
- 'bootstrap',
56
- 'schemas',
57
- 'jit',
17
+ 'changeDetection',
58
18
  ],
59
- // https://angular.dev/api/core/Pipe
60
- Pipe: ['name', 'standalone', 'pure'],
19
+ Directive: ['selector', 'standalone'],
20
+ NgModule: ['declarations', 'imports', 'exports', 'providers', 'bootstrap'],
21
+ Pipe: ['name', 'standalone'],
61
22
  };
62
23
  exports.RULE_NAME = 'sort-keys-in-type-decorator';
63
24
  exports.default = (0, create_eslint_rule_1.createESLintRule)({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@angular-eslint/eslint-plugin",
3
- "version": "19.8.1-alpha.1",
3
+ "version": "19.8.1",
4
4
  "description": "ESLint plugin for Angular applications, following https://angular.dev/style-guide",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",
@@ -18,11 +18,11 @@
18
18
  "LICENSE"
19
19
  ],
20
20
  "dependencies": {
21
- "@angular-eslint/bundled-angular-compiler": "19.8.1-alpha.1",
22
- "@angular-eslint/utils": "19.8.1-alpha.1"
21
+ "@angular-eslint/bundled-angular-compiler": "19.8.1",
22
+ "@angular-eslint/utils": "19.8.1"
23
23
  },
24
24
  "devDependencies": {
25
- "@angular-eslint/test-utils": "19.8.1-alpha.1"
25
+ "@angular-eslint/test-utils": "19.8.1"
26
26
  },
27
27
  "peerDependencies": {
28
28
  "@typescript-eslint/utils": "^7.11.0 || ^8.0.0",