|
|
@ -40,7 +40,7 @@ ReactDOM.render( |
|
|
|
|
|
|
|
If you're curious to see more examples of how JSX is converted to JavaScript, you can try out [the online Babel compiler](babel://jsx-simple-example). |
|
|
|
|
|
|
|
The component can either be provided as a string, or as a subclass of `React.Component`, or a plain function for stateless components. |
|
|
|
The component can either be provided as a string, as a subclass of `React.Component`, or a plain function. |
|
|
|
|
|
|
|
If you get tired of typing `React.createElement` so much, one common pattern is to assign a shorthand: |
|
|
|
|
|
|
|