lemmy-ui/src/client/index.tsx

19 lines
410 B
TypeScript
Raw Normal View History

2021-02-22 02:39:04 +00:00
import { hydrate } from "inferno-hydrate";
import { BrowserRouter } from "inferno-router";
import { App } from "../shared/components/app/app";
import { initializeSite } from "../shared/utils";
2020-08-23 04:04:58 +00:00
const site = window.isoData.site_res;
2020-10-26 07:09:44 +00:00
initializeSite(site);
2020-08-23 04:04:58 +00:00
const wrapper = (
<BrowserRouter>
<App />
2020-08-23 04:04:58 +00:00
</BrowserRouter>
);
let root = document.getElementById("root");
if (root) {
hydrate(wrapper, root);
}