MyCrypto/common/index.jsx
henrynguyen5 ac5d713ae1 Revert "Hot module reload fixes (#181)"
This reverts commit b59298ec0e3f4a70c1b5aa4e128778d803793572.
2017-09-18 02:31:52 -04:00

34 lines
839 B
JavaScript

// Application styles must come first in order, to allow for overrides
import 'assets/styles/etherwallet-master.less';
import 'font-awesome/scss/font-awesome.scss';
import 'sass/styles.scss';
import React from 'react';
import { render } from 'react-dom';
import { syncHistoryWithStore } from 'react-router-redux';
import { Root } from 'components';
import { Routing, history } from './routing';
import { store } from './store';
const renderRoot = Root => {
let syncedHistory = syncHistoryWithStore(history, store);
render(
<Root
key={Math.random()}
routes={Routing}
history={syncedHistory}
store={store}
/>,
document.getElementById('app')
);
};
renderRoot(Root);
if (module.hot) {
module.hot.accept('reducers/index', () =>
store.replaceReducer(require('reducers/index').default)
);
}