forked from facebook/react
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsystemjs.html
More file actions
46 lines (43 loc) · 1.17 KB
/
systemjs.html
File metadata and controls
46 lines (43 loc) · 1.17 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<html>
<body>
<script src="https://unpkg.com/systemjs@0.19.41/dist/system.js"></script>
<style>
.example-appear {
opacity: 0.01;
}
.example-appear.example-appear-active {
opacity: 1;
transition: opacity .5s ease-in;
}
</style>
<div id="container"></div>
<script>
System.config({
paths: {
react: '../build/react-with-addons.js',
'react-dom': '../build/react-dom.js'
}
});
Promise.all([
System.import("react"),
System.import("react-dom")
]).then(function (deps) {
var React = deps[0];
var ReactDOM = deps[1];
var CSSTransitionGroup = React.addons.CSSTransitionGroup;
ReactDOM.render(
React.createElement(CSSTransitionGroup, {
transitionName: 'example',
transitionAppear: true,
transitionAppearTimeout: 500,
transitionEnterTimeout: 0,
transitionLeaveTimeout: 0,
}, React.createElement('h1', null,
'Hello World!'
)),
document.getElementById('container')
);
});
</script>
</body>
</html>