react-toolbox/docs/app/index.jsx

24 lines
836 B
React
Raw Normal View History

2015-10-29 08:33:21 +03:00
import React from 'react';
import ReactDOM from 'react-dom';
2015-10-30 12:40:55 +03:00
import { Router, Route, IndexRoute } from 'react-router';
import { App } from 'react-toolbox';
import { createHashHistory } from 'history';
2015-10-29 08:33:21 +03:00
2015-10-30 12:40:55 +03:00
import Home from './components/layout/home';
import Main from './components/layout/main';
import Playground from './components/layout/playground';
import Documentation from './components/layout/main/components/documentation';
ReactDOM.render((
<Router history={createHashHistory()}>
<Route component={App}>
<Route path="/" component={Home} />
<Route component={Main}>
<Route path="/components/:component" component={Documentation} />
<Route path="/playground" component={Playground} />
</Route>
<IndexRoute component={Home}/>
</Route>
</Router>
), document.getElementById('app'));