1
0
mirror of https://github.com/yldio/copilot.git synced 2025-01-24 18:00:11 +02:00
copilot/spikes/stacks/redux-thunk/src/client/root.js

42 lines
902 B
JavaScript
Raw Normal View History

2016-10-14 12:45:12 +03:00
const React = require('react');
const ReactHotLoader = require('react-hot-loader');
const ReactRouter = require('react-router');
const ReactRedux = require('react-redux');
const App = require('./containers/app');
const NotFound = require('./containers/not-found');
const Home = require('./containers/home');
const Print = require('./containers/print');
const store = require('./store');
const {
AppContainer
} = ReactHotLoader;
const {
BrowserRouter,
Miss,
Match
} = ReactRouter;
const {
Provider
} = ReactRedux;
module.exports = () => {
return (
<AppContainer>
<Provider store={store()}>
<BrowserRouter>
<App>
<Match exactly pattern='/' component={Home} />
<Match pattern='/print' component={Print} />
<Miss component={NotFound}/>
</App>
</BrowserRouter>
</Provider>
</AppContainer>
);
};