mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Upgrade to React@18 (#5172)
* upgrade to react@18 read more: https://reactjs.org/blog/2022/03/29/react-v18.html
This commit is contained in:
1 parent
06e7dfce5e
commit
71b222f9d0
6 files changed
+46
-49
No files matched your search
@@ -5,7 +5,6 @@
|
||||
import { delay } from "../../../../common/utils";
|
||||
import { broadcastMessage } from "../../../../common/ipc";
|
||||
import logger from "../../../../common/logger";
|
||||
import { unmountComponentAtNode } from "react-dom";
|
||||
import type { ExtensionLoading } from "../../../../extensions/extension-loader";
|
||||
import type { CatalogEntityRegistry } from "../../../api/catalog-entity-registry";
|
||||
import { bundledExtensionsLoaded } from "../../../../common/ipc/extension-handling";
|
||||
@@ -34,10 +33,9 @@ export const initRootFrame =
|
||||
lensProtocolRouterRenderer,
|
||||
ipcRenderer,
|
||||
registerIpcListeners,
|
||||
|
||||
catalogEntityRegistry,
|
||||
}: Dependencies) =>
|
||||
async (rootElem: HTMLElement) => {
|
||||
async (unmountRoot: () => void) => {
|
||||
catalogEntityRegistry.init();
|
||||
|
||||
try {
|
||||
@@ -72,6 +70,6 @@ export const initRootFrame =
|
||||
window.addEventListener("beforeunload", () => {
|
||||
logger.info(`${logPrefix} Unload app`);
|
||||
|
||||
unmountComponentAtNode(rootElem);
|
||||
unmountRoot();
|
||||
});
|
||||
};
|
||||
Reference in new issue
Block a user