mark as jsx

pull/21833/head
David Baker 2016-07-08 15:59:34 +01:00
parent 1a3bc814e1
commit 0fdc2d817c
1 changed files with 1 additions and 1 deletions

View File

@ -147,7 +147,7 @@ React
-----
- Use ES6 classes, although bear in mind a lot of code uses createClass.
- Pull out functions in props to the class, generally as specific event handlers:
```
```jsx
<Foo onClick={function(ev) {doStuff();}}> // Bad
<Foo onClick={(ev) => {doStuff();}}> // Equally bad
<Foo onClick={this.doStuff}> // Better