Skip to content

Instantly share code, notes, and snippets.

@StoneCypher
Last active January 8, 2018 05:57
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save StoneCypher/d18b5d2d72a0bbf4886022aa5cc84265 to your computer and use it in GitHub Desktop.
Save StoneCypher/d18b5d2d72a0bbf4886022aa5cc84265 to your computer and use it in GitHub Desktop.
Toy react bootstrap from CDN for Francisco
<!doctype html>
<html>
<head>
<script src="https://fb.me/react-15.0.0.js"></script>
<script src="https://fb.me/react-dom-15.0.0.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/babel-core/5.8.34/browser.min.js"></script>
<script type="text/babel">
// this is about React internals; you may safely ignore it
const process = { env: {} };
// this is a simple react control
const ExampleControl = props => <div>Hello, {props.name || 'world'}!</div>;
const onLoadDo = () =>
ReactDOM.render( <ExampleControl name="Francisco"/>, document.getElementById('tgt') );
window.onload = onLoadDo;
</script>
</head>
<body><div id="tgt"></div></body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment