bitburner-src/src/index.tsx
Olivier Gagnon 50cf362b3b v0.55.0
2021-10-01 16:22:33 -04:00

27 lines
510 B
TypeScript

import React from "react";
import ReactDOM from "react-dom";
import { TTheme as Theme, ThemeEvents, refreshTheme } from "./ui/React/Theme";
import { LoadingScreen } from "./ui/LoadingScreen";
ReactDOM.render(
<Theme>
<LoadingScreen />
</Theme>,
document.getElementById("root"),
);
function rerender(): void {
refreshTheme();
ReactDOM.render(
<Theme>
<LoadingScreen />
</Theme>,
document.getElementById("root"),
);
}
(function () {
ThemeEvents.subscribe(rerender);
})();