keycloak-theme-react/src/index.tsx
2023-02-26 12:32:22 +01:00

13 lines
447 B
TypeScript

import { createRoot } from "react-dom/client";
import { StrictMode, lazy, Suspense } from "react";
import { kcContext } from "./keycloakTheme/kcContext";
const App = lazy(() => import("./App"));
const KcApp = lazy(() => import("./keycloakTheme/KcApp"));
createRoot(document.getElementById("root")!).render(
<StrictMode>
<Suspense>{kcContext === undefined ? <App /> : <KcApp kcContext={kcContext} />}</Suspense>
</StrictMode>,
);