diff --git a/frontend/src/index.js b/frontend/src/index.js index 6472914f4..cb9240c7e 100644 --- a/frontend/src/index.js +++ b/frontend/src/index.js @@ -1,10 +1,8 @@ import { createBrowserHistory } from 'history'; import React from 'react'; import { render } from 'react-dom'; -import createAppStore from 'Store/createAppStore'; import { fetchTranslations } from 'Utilities/String/translate'; -// import App from './App/App'; import './preload'; import './polyfills'; import 'Diag/ConsoleApi'; @@ -12,10 +10,13 @@ import 'Styles/globals.css'; import './index.css'; const history = createBrowserHistory(); -const store = createAppStore(history); const hasTranslationsError = !await fetchTranslations(); + +const { default: createAppStore } = await import('Store/createAppStore'); const { default: App } = await import('./App/App'); +const store = createAppStore(history); + render(