fix: use createRoot instead of ReactDom.render
parent
329dff1adb
commit
1efc5d2beb
@ -1,6 +1,7 @@
|
|||||||
// const $body = $(document.body);
|
|
||||||
|
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
import { createRoot } from 'react-dom/client';
|
||||||
import { AboutView } from '../components/AboutView';
|
import { AboutView } from '../components/AboutView';
|
||||||
|
|
||||||
window.ReactDOM.render(<AboutView />, document.getElementById('root'));
|
const container = document.getElementById('root');
|
||||||
|
const root = createRoot(container!);
|
||||||
|
root.render(<AboutView />);
|
||||||
|
@ -1,4 +1,7 @@
|
|||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
import { createRoot } from 'react-dom/client';
|
||||||
import { DebugLogView } from '../components/DebugLogView';
|
import { DebugLogView } from '../components/DebugLogView';
|
||||||
|
|
||||||
window.ReactDOM.render(<DebugLogView />, document.getElementById('root'));
|
const container = document.getElementById('root');
|
||||||
|
const root = createRoot(container!);
|
||||||
|
root.render(<DebugLogView />);
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
// const $body = $(document.body);
|
|
||||||
|
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
import { createRoot } from 'react-dom/client';
|
||||||
import { SessionPasswordPrompt } from '../components/SessionPasswordPrompt';
|
import { SessionPasswordPrompt } from '../components/SessionPasswordPrompt';
|
||||||
|
|
||||||
window.ReactDOM.render(<SessionPasswordPrompt />, document.getElementById('root'));
|
const container = document.getElementById('root');
|
||||||
|
const root = createRoot(container!);
|
||||||
|
root.render(<SessionPasswordPrompt />);
|
||||||
|
Loading…
Reference in New Issue