-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.jsx
39 lines (29 loc) · 940 Bytes
/
index.jsx
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
/*global document*/
import React from "react/addons";
import context from "./src/utils/context";
import {Router, Route} from "react-router";
import HashHistory from "react-router/lib/HashHistory";
import Alt from "alt";
import Flux from "./src/flux/alt";
import Deck from "./presentation/deck";
import config from "./presentation/config";
require("normalize.css");
require("./themes/default/index.css");
require("highlight.js/styles/monokai_sublime.css");
const flux = new Flux();
Alt.debug("flux", flux);
class Presentation extends React.Component {
render() {
return <Deck/>;
}
}
Presentation.contextTypes = {
router: React.PropTypes.object
};
Presentation = context(Presentation, {styles: config.theme, print: config.print, flux});
React.render(
<Router history={new HashHistory()}>
<Route path="/" component={Presentation} />
<Route path="/:slide" component={Presentation} />
</Router>
, document.body);