msgba-web/js-src/index.tsx

19 lines
457 B
TypeScript

"use strict";
import * as React from 'react';
import * as ReactDOMClient from 'react-dom/client';
import Endian from '@msgba/endian';
import Page from '@msgba/components/page';
const body = document.querySelector('body');
if (body != null) {
fillBody(body);
}
function fillBody(body: HTMLElement) {
const app = document.createElement('div');
body.appendChild(app);
const root = ReactDOMClient.createRoot(app);
root.render(<Page/>);
}