Skip to content

Latest commit

 

History

History
43 lines (30 loc) · 874 Bytes

File metadata and controls

43 lines (30 loc) · 874 Bytes

ember/template-no-args-paths

Disallow the use of @args in template paths. Instead of accessing arguments through @args.foo, use @foo directly.

Rule Details

This rule prevents the use of @args. prefix in template paths. In Ember templates, arguments should be accessed directly using @argName syntax rather than through the @args object.

Examples

Examples of incorrect code for this rule:

<template>
  {{@args.foo}}
</template>
<template>
  <div>{{@args.name}}</div>
</template>

Examples of correct code for this rule:

<template>
  {{@foo}}
</template>
<template>
  <div>{{@name}}</div>
</template>

References