From 9ffd3b51502d0c2c0373c6c6a5172c6246c05a37 Mon Sep 17 00:00:00 2001 From: Karl Horky Date: Thu, 4 Aug 2022 09:48:04 +0200 Subject: [PATCH] Add example with embedded expression and ternary --- docs/rules/jsx-no-useless-fragment.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/rules/jsx-no-useless-fragment.md b/docs/rules/jsx-no-useless-fragment.md index 79040dbf70..3712cbd1a9 100644 --- a/docs/rules/jsx-no-useless-fragment.md +++ b/docs/rules/jsx-no-useless-fragment.md @@ -27,6 +27,8 @@ Examples of **incorrect** code for this rule:
+ +{showFullName ? <>{fullName} : <>{firstName}} ``` Examples of **correct** code for this rule: @@ -55,6 +57,8 @@ const cat = <>meow {item.value} + +{showFullName ? fullName : firstName} ``` ### `allowExpressions`