Skip to content

Latest commit

 

History

History
47 lines (35 loc) · 909 Bytes

File metadata and controls

47 lines (35 loc) · 909 Bytes

ember/template-no-shadowed-elements

This rule prevents ambiguity in situations where a yielded block param which starts with a lower case letter is also used within the block itself as an element name.

Examples

This rule forbids the following:

<FooBar as |div|>
  <div></div>
</FooBar>

This rule allows the following:

{{#foo-bar as |Baz|}}
  <Baz />
{{/foo-bar}}
<FooBar as |Baz|>
  <Baz />
</FooBar>
{{#with foo=(component 'blah-zorz') as |Div|}}
  <Div />
{{/with}}
<Foo as |bar|>
  <bar.baz />
</Foo>

References