[UPdate] Add error boundary.
This commit is contained in:
@@ -22,6 +22,7 @@ import { ModalController } from "./modal_controller/ModalController";
|
||||
import { SnackbarController } from "./snackbar_controller/SnackbarController";
|
||||
import styles from "./App.module.scss";
|
||||
import { useIsBackendReady, useIsSoftwareUpdating, useIsVrctAvailable, useWindow } from "@logics_common";
|
||||
import { AppErrorBoundary } from "./error_boundary/AppErrorBoundary";
|
||||
|
||||
export const App = () => {
|
||||
const { currentIsVrctAvailable } = useIsVrctAvailable();
|
||||
@@ -32,22 +33,24 @@ export const App = () => {
|
||||
|
||||
return (
|
||||
<div className={styles.container}>
|
||||
<KeyEventController />
|
||||
<StartPythonController />
|
||||
<GlobalHotKeyController />
|
||||
<UiLanguageController />
|
||||
<ConfigPageCloseTriggerController />
|
||||
<UiSizeController />
|
||||
<FontFamilyController />
|
||||
<TransparencyController />
|
||||
<WindowGeometryController />
|
||||
<AppErrorBoundary >
|
||||
<KeyEventController />
|
||||
<StartPythonController />
|
||||
<GlobalHotKeyController />
|
||||
<UiLanguageController />
|
||||
<ConfigPageCloseTriggerController />
|
||||
<UiSizeController />
|
||||
<FontFamilyController />
|
||||
<TransparencyController />
|
||||
<WindowGeometryController />
|
||||
|
||||
{(currentIsBackendReady.data === false || currentIsVrctAvailable.data === false)
|
||||
? <SplashComponent />
|
||||
: <Contents key={i18n.language} fetchPluginsHasRunRef={fetchPluginsHasRunRef} />
|
||||
}
|
||||
{(currentIsBackendReady.data === false || currentIsVrctAvailable.data === false)
|
||||
? <SplashComponent />
|
||||
: <Contents key={i18n.language} fetchPluginsHasRunRef={fetchPluginsHasRunRef} />
|
||||
}
|
||||
|
||||
<SnackbarController />
|
||||
<SnackbarController />
|
||||
</AppErrorBoundary>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user