[guide] [react] boolean in jsx alignment

This commit is contained in:
Andrew Scheuermann
2018-07-11 16:26:22 -07:00
committed by Jordan Harband
parent b6a268f780
commit a12dec90d1

View File

@@ -193,6 +193,25 @@ This style guide is mostly based on the standards that are currently prevalent i
>
<Quux />
</Foo>
// bad
{showButton &&
<Button />
}
// bad
{
showButton &&
<Button />
}
// good
{showButton && (
<Button />
)}
// good
{showButton && <Button />}
```
## Quotes