Skip to content
This repository was archived by the owner on Apr 11, 2019. It is now read-only.

Commit 8aff0d4

Browse files
committed
Fix development set up issue
There was an issue when developing locally where the console would show this error: > Error: React-Hot-Loader: AppContainer should be patched
1 parent e170e8c commit 8aff0d4

File tree

2 files changed

+9
-28
lines changed

2 files changed

+9
-28
lines changed

src/components/app.jsx

Lines changed: 0 additions & 9 deletions
This file was deleted.

src/index.jsx

Lines changed: 9 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,19 @@
11
import Raven from 'raven-js';
22
import { render } from 'react-dom';
3-
import { AppContainer } from 'react-hot-loader';
43
import { HashRouter } from 'react-router-dom';
5-
import App from './components/app';
64
import Boundary from './components/errorBoundary';
5+
import Routes from './components/routes';
6+
import './style.css';
77

88
if (process.env.NODE_ENV === 'production') {
99
Raven.config('https://60b05bc4ef794a6c9e30e86e6a316083@sentry.io/300397').install();
1010
}
1111

12-
const root = document.getElementById('root');
13-
const load = () => render(
14-
<AppContainer>
15-
<HashRouter>
16-
<Boundary>
17-
<App />
18-
</Boundary>
19-
</HashRouter>
20-
</AppContainer>,
21-
root,
12+
render(
13+
<HashRouter>
14+
<Boundary>
15+
<Routes />
16+
</Boundary>
17+
</HashRouter>,
18+
document.getElementById('root'),
2219
);
23-
24-
// This is needed for Hot Module Replacement
25-
if (module.hot) {
26-
module.hot.accept('./components/app', load);
27-
}
28-
29-
load();

0 commit comments

Comments
 (0)