make typescript compilation work

This commit is contained in:
Alexander Bentkamp
2022-10-19 13:23:20 +02:00
parent d3fbfaa548
commit e175733b44
4 changed files with 11 additions and 13 deletions
-11
View File
@@ -1,11 +0,0 @@
import React from 'react'
import { createRoot } from 'react-dom/client';
import './index.css';
import App from './App';
self.$RefreshReg$ = () => {};
self.$RefreshSig$ = () => () => {};
const container = document.getElementById('root');
const root = createRoot(container); // createRoot(container!) if you use TypeScript
root.render(<App />);
+8
View File
@@ -0,0 +1,8 @@
import * as React from 'react';
import { createRoot } from 'react-dom/client';
import './index.css';
import App from './App';
const container = document.getElementById('root');
const root = createRoot(container!);
root.render(<App />);