You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|[template-no-obscure-array-access](docs/rules/template-no-obscure-array-access.md)| disallow obscure array access patterns like [email protected]|![badge-strict-gjs][]![badge-strict-gts][]|||
280
282
|[template-no-obsolete-elements](docs/rules/template-no-obsolete-elements.md)| disallow obsolete HTML elements |![badge-strict-gjs][]![badge-strict-gts][]|||
281
283
|[template-no-outlet-outside-routes](docs/rules/template-no-outlet-outside-routes.md)| disallow {{outlet}} outside of route templates ||||
282
284
|[template-no-page-title-component](docs/rules/template-no-page-title-component.md)| disallow usage of ember-page-title component |![badge-strict-gjs][]![badge-strict-gts][]|||
@@ -288,9 +290,11 @@ rules in templates can be disabled with eslint directives with mustache or html
288
290
|[template-no-trailing-spaces](docs/rules/template-no-trailing-spaces.md)| disallow trailing whitespace at the end of lines in templates |![badge-strict-gjs][]![badge-strict-gts][]| 🔧 ||
|[template-no-unnecessary-curly-parens](docs/rules/template-no-unnecessary-curly-parens.md)| disallow unnecessary curlies around single values |![badge-strict-gjs][]![badge-strict-gts][]|||
291
294
|[template-no-unnecessary-service-injection-argument](docs/rules/template-no-unnecessary-service-injection-argument.md)| disallow unnecessary service injection argument |![badge-strict-gjs][]![badge-strict-gts][]|||
292
295
|[template-no-unused-block-params](docs/rules/template-no-unused-block-params.md)| disallow unused block parameters in templates ||||
293
296
|[template-no-valueless-arguments](docs/rules/template-no-valueless-arguments.md)| disallow valueless named arguments |![badge-strict-gjs][]![badge-strict-gts][]|||
297
+
|[template-no-whitespace-for-layout](docs/rules/template-no-whitespace-for-layout.md)| disallow using whitespace for layout purposes |![badge-strict-gjs][]![badge-strict-gts][]|||
294
298
|[template-no-yield-only](docs/rules/template-no-yield-only.md)| disallow components that only yield |![badge-strict-gjs][]![badge-strict-gts][]|||
295
299
|[template-no-yield-to-default](docs/rules/template-no-yield-to-default.md)| disallow yield to default block |![badge-strict-gjs][]![badge-strict-gts][]|||
296
300
|[template-require-button-type](docs/rules/template-require-button-type.md)| require button elements to have a valid type attribute |![badge-strict-gjs][]![badge-strict-gts][]| 🔧 ||
@@ -426,7 +430,9 @@ rules in templates can be disabled with eslint directives with mustache or html
|[template-no-scope-outside-table-headings](docs/rules/template-no-scope-outside-table-headings.md)| disallow scope attribute outside th/td elements |![badge-strict-gjs][]![badge-strict-gts][]|||
429
434
|[template-no-shadowed-elements](docs/rules/template-no-shadowed-elements.md)| disallow shadowing of built-in HTML elements |![badge-strict-gjs][]![badge-strict-gts][]|||
💼 This rule is enabled in the following [configs](https://github.com/ember-cli/eslint-plugin-ember#-configurations): `strict-gjs`, `strict-gts`.
4
+
5
+
<!-- end auto-generated rule header -->
6
+
7
+
✅ The `extends: 'plugin:ember/strict-gjs'` or `extends: 'plugin:ember/strict-gts'` property in a configuration file enables this rule.
8
+
9
+
In Ember route templates, the model should be accessed via `this.model` in the controller or component, not as an `@model` argument. The `@model` argument pattern is more appropriate for components. This rule primarily targets `.hbs` files in the `templates/` directory.
10
+
11
+
## Rule Details
12
+
13
+
This rule disallows the use of `@model` argument in route templates (`.hbs` files in `templates/` directory).
14
+
15
+
## Examples
16
+
17
+
Examples of **incorrect** code for this rule (in route templates):
💼 This rule is enabled in the following [configs](https://github.com/ember-cli/eslint-plugin-ember#-configurations): `strict-gjs`, `strict-gts`.
4
+
5
+
<!-- end auto-generated rule header -->
6
+
7
+
✅ The `extends: 'plugin:ember/strict-gjs'` or `extends: 'plugin:ember/strict-gts'` property in a configuration file enables this rule.
8
+
9
+
Disallow obscure array access patterns like `[email protected]` or `objectPath.[].property` in templates.
10
+
11
+
## Rule Details
12
+
13
+
This rule discourages the use of `@each` and `[]` property access patterns in templates, which can be obscure and difficult to understand. Instead, use computed properties, helpers, or explicit iteration.
💼 This rule is enabled in the following [configs](https://github.com/ember-cli/eslint-plugin-ember#-configurations): `strict-gjs`, `strict-gts`.
4
+
5
+
<!-- end auto-generated rule header -->
6
+
7
+
✅ The `extends: 'plugin:ember/strict-gjs'` or `extends: 'plugin:ember/strict-gts'` property in a configuration file enables this rule.
8
+
9
+
Disallow unnecessary curlies around simple values in templates. This is a stylistic rule that promotes cleaner template code. It only flags simple single identifiers without path separators or parameters.
10
+
11
+
## Rule Details
12
+
13
+
This rule discourages the use of mustache curlies `{{}}` around simple single identifiers when they could potentially be expressed more simply.
0 commit comments