2018-09-09 17:22:44 -04:00
|
|
|
import BrowserRouter from 'react-router-dom/BrowserRouter';
|
|
|
|
import React from 'react';
|
|
|
|
import { hydrate } from 'react-dom';
|
|
|
|
|
|
|
|
import App from './frontend/app';
|
|
|
|
|
|
|
|
const data = window.__PRELOADED_STATE__;
|
|
|
|
|
|
|
|
hydrate(
|
|
|
|
<BrowserRouter>
|
2018-09-13 15:41:42 -04:00
|
|
|
<App user={data.user} building={data.building} />
|
2018-09-09 17:22:44 -04:00
|
|
|
</BrowserRouter>,
|
|
|
|
document.getElementById('root')
|
|
|
|
);
|
|
|
|
|
|
|
|
if (module.hot) {
|
|
|
|
module.hot.accept();
|
|
|
|
}
|