Skip to content

Latest commit

 

History

History
40 lines (28 loc) · 978 Bytes

File metadata and controls

40 lines (28 loc) · 978 Bytes

ember/template-no-unnecessary-curly-parens

💼 This rule is enabled in the 📋 template-lint-migration config.

🔧 This rule is automatically fixable by the --fix CLI option.

Disallow unnecessary parentheses enclosing statements in curlies. When invoking a helper with arguments, the outer parentheses around the entire expression are unnecessary.

Examples

This rule forbids the following:

<template>
  {{(concat "a" "b")}}
</template>
<template>
  {{(helper a="b")}}
</template>

This rule allows the following:

<template>
  {{foo}}
  {{(foo)}}
  {{concat "a" "b"}}
  {{concat (capitalize "foo") "-bar"}}
</template>

References