Skip to content

Instantly share code, notes, and snippets.

@chantastic
Created November 23, 2015 10:52
Show Gist options
  • Save chantastic/b00af6847de0d5bf4289 to your computer and use it in GitHub Desktop.
Save chantastic/b00af6847de0d5bf4289 to your computer and use it in GitHub Desktop.
In June of 2015, I started a small short series of sceencasts series with Sitepoint on React.
The series was created on React v0.13. React v0.14 introduced pretty big changes to the way simple projects like this are setup.
Here is the boilerplate, as it should be for React v0.14.
I hope this helps.
Michael (@chantastic)
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>React 0.14 Boilerplate</title>
<script src="https://cdnjs.cloudflare.com/ajax/libs/react/0.14.3/react.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/react/0.14.3/react-dom.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/babel-core/5.8.23/browser.min.js"></script>
</head>
<body>
<div id="app"></div>
<script type="text/babel">
var Greeting = React.createClass({
render: function () {
return <h2>Hello React!</h2>;
}
});
ReactDOM.render(<Greeting />, document.getElementById("app"))
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment