Files
react/fixtures/packaging/systemjs/dev.html
T
2017-03-23 15:36:23 +00:00

27 lines
691 B
HTML

<html>
<body>
<script src="https://unpkg.com/systemjs@0.19.41/dist/system.js"></script>
<div id="container"></div>
<script>
System.config({
paths: {
react: '../../../build/rollup/dist/react.dev.js',
'react-dom': '../../../build/rollup/dist/react-dom.dev.js'
}
});
Promise.all([
System.import("react"),
System.import("react-dom")
]).then(function (deps) {
var React = deps[0];
var ReactDOM = deps[1];
ReactDOM.render(
React.createElement('h1', null, 'Hello World!'),
document.getElementById('container')
);
});
</script>
</body>
</html>