Skip to content

Commit 762ce01

Browse files
author
Robert Mosolgo
committed
Merge pull request #388 from kaiwood/patch-1
Update README to hint for newer syntax
2 parents 0e5ded5 + bf217f4 commit 762ce01

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -332,6 +332,14 @@ Component = React.createClass
332332
`<ExampleComponent videos={this.props.videos} />`
333333
```
334334

335+
Alternatively, the newer ES6 style class based syntax can be used like this:
336+
337+
```coffee
338+
class Component extends React.Component
339+
render: ->
340+
`<ExampleComponent videos={this.props.videos} />`
341+
```
342+
335343
## Extending `react-rails`
336344

337345
You can extend some of the core functionality of `react-rails` by injecting new implementations during configuration.

0 commit comments

Comments
 (0)