Skip to content

Commit 780be0d

Browse files
committed
[guide][react] Add missing parenthesis in «Refs» recommendation
As is, actual «good» usage fires the arrow-parens rule. Parenthesis are needed to follow the current style guide.
1 parent 664877a commit 780be0d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

react/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -378,7 +378,7 @@
378378
379379
// good
380380
<Foo
381-
ref={ref => { this.myRef = ref; }}
381+
ref={(ref) => { this.myRef = ref; }}
382382
/>
383383
```
384384

0 commit comments

Comments
 (0)