Skip to content

Fix template-no-attrs-in-components: align detection with upstream#2688

Open
johanrd wants to merge 3 commits intoember-cli:masterfrom
johanrd:day_fix/template-no-attrs-in-components
Open

Fix template-no-attrs-in-components: align detection with upstream#2688
johanrd wants to merge 3 commits intoember-cli:masterfrom
johanrd:day_fix/template-no-attrs-in-components

Conversation

@johanrd
Copy link
Copy Markdown
Contributor

@johanrd johanrd commented Apr 13, 2026

Summary

  • Adds file-path gate: only runs in component template paths (matching upstream's heuristic)
  • Flags bare attrs.* (not this.attrs.* which is a non-existent API)
  • Adds templateMode: 'loose' and originallyFrom metadata

Test plan

  • {{attrs.foo}} in component template path → flagged
  • {{this.attrs.foo}} → never flagged (not a real Ember API)
  • {{attrs.foo}} in non-component template path → not flagged

johanrd added 3 commits April 13, 2026 14:44
The port flagged this.attrs.* (which is not a real Ember API) and ran
on all templates. Upstream gates on file path (templates/components/,
components/*/template, ui/components/, -components/) and flags bare
attrs.* — the pre-Octane args-leakage pattern. Restore upstream's
behavior.
@johanrd johanrd marked this pull request as ready for review April 13, 2026 17:20
@johanrd johanrd force-pushed the day_fix/template-no-attrs-in-components branch from 1577807 to 11afc7a Compare April 13, 2026 17:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant