Skip to content

Commit 1c1f23f

Browse files
committed
add test case
1 parent 4c1f66a commit 1c1f23f

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

tests/lib/rules/jsx-curly-brace-presence.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -468,6 +468,17 @@ ruleTester.run('jsx-curly-brace-presence', rule, {
468468
`,
469469
features: ['no-ts'],
470470
options: ['never'],
471+
},
472+
// legit as this single template literal might be used for type casting
473+
{
474+
code: '<App label={`${label}`} />',
475+
output: '<App label={label} />',
476+
options: ['never'],
477+
},
478+
{
479+
code: '<App>{`${label}`}</App>',
480+
output: '<App>{label}</App>',
481+
options: ['never'],
471482
}
472483
)),
473484

0 commit comments

Comments
 (0)