Skip to content

Instantly share code, notes, and snippets.

@uxnjs01
Created August 21, 2015 02:29
Show Gist options
  • Save uxnjs01/820471607037135184bf to your computer and use it in GitHub Desktop.
Save uxnjs01/820471607037135184bf to your computer and use it in GitHub Desktop.
Rendering HelloWorld Component
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>React.js Hello World!</title>
<script src="https://fb.me/react-0.13.3.js"></script>
<script src="https://fb.me/JSXTransformer-0.13.3.js"></script>
</head>
<body>
<div id="hello"></div>
<script type="text/jsx">
var HelloWorld = React.createClass({
render: function() {
return (
<h1>Hello, World!</h1>
);
}
});
React.render(<HelloWorld />, document.getElementById('hello'));
</script>
</body>
</html>
@uxnjs01
Copy link
Author

uxnjs01 commented Aug 21, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment