authelia/web/src/index.tsx
Amir Zarrinkafsh fa143ea029
fix(web): update client rendering method (#3106)
This PR utilises the React 18 Client Rendering API along with createRoot as opposed to the React 17 ReactDOM.render method.
2022-04-04 09:39:18 +10:00

17 lines
526 B
TypeScript

import React from "react";
import { createRoot } from "react-dom/client";
import "@root/index.css";
import App from "@root/App";
import * as serviceWorker from "@root/serviceWorker";
import "@i18n/index.ts";
const root = createRoot(document.getElementById("root")!);
root.render(<App />);
// If you want your app to work offline and load faster, you can change
// unregister() to register() below. Note this comes with some pitfalls.
// Learn more about service workers: https://bit.ly/CRA-PWA
serviceWorker.unregister();