-
-
Notifications
You must be signed in to change notification settings - Fork 635
/
app.js
70 lines (63 loc) · 1.42 KB
/
app.js
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
import { Component, render } from 'inferno';
class Demo extends Component {
constructor(props, context) {
super(props, context);
this.state = {
numPoints: 0
};
this.updateCount = this.updateCount.bind(this);
}
updateCount(e) {
this.setState({
numPoints: e.target.value
});
}
componentDidMount() {
this.setState({
numPoints: 1000
});
}
render(props, state) {
return (
<div className="app-wrapper">
<p>
The infinite sum
<math display="block">
<mrow>
<munderover>
<mo>∑</mo>
<mrow>
<mi>n</mi>
<mo>=</mo>
<mn>1</mn>
</mrow>
<mrow>
<mo>+</mo>
<mn>∞</mn>
</mrow>
</munderover>
<mfrac>
<mn>1</mn>
<msup>
<mi>n</mi>
<mn>2</mn>
</msup>
</mfrac>
</mrow>
</math>
is equal to the real number
<math display="inline">
<mfrac>
<msup>
<mi>π</mi>
<mn>2</mn>
</msup>
<mn>6</mn>
</mfrac></math
>.
</p>
</div>
);
}
}
render(<Demo />, document.getElementById('app'));