ing
This commit is contained in:
parent
6f7f35317f
commit
90fb76955e
|
@ -19,6 +19,11 @@ import {
|
|||
routerMiddleware,
|
||||
} from 'react-router-redux';
|
||||
|
||||
import {
|
||||
createHashHistory,
|
||||
History,
|
||||
} from 'history';
|
||||
|
||||
import {
|
||||
AppContainer,
|
||||
} from 'react-hot-loader';
|
||||
|
@ -41,11 +46,13 @@ class WebAppApplication {
|
|||
|
||||
public constructor() {
|
||||
this.container = document.getElementById('appContainer');
|
||||
this.history = createHashHistory();
|
||||
}
|
||||
|
||||
public async run(): Promise<void> {
|
||||
try {
|
||||
this.renderLoading();
|
||||
this.renderApp();
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
}
|
||||
|
@ -100,7 +107,7 @@ class WebAppApplication {
|
|||
private rederDevelopment(): void {
|
||||
if (module.hot) {
|
||||
module.hot.accept('./pages/webapp', async () => {
|
||||
const NextApp = (await import('./pages/webapp')).default;
|
||||
const NextApp = (await require('./pages/webapp')).default;
|
||||
ReactDOM.render(
|
||||
<AppContainer>
|
||||
<Provider store={this.store}>
|
||||
|
|
Loading…
Reference in New Issue
Block a user