perf(main): remove unnecessary React.mode
This caused to #1afaa4c
This commit is contained in:
21
src/main.tsx
21
src/main.tsx
@@ -4,7 +4,6 @@ import "./assets/styles/index.scss";
|
||||
|
||||
import { ResizeObserver } from "@juggle/resize-observer";
|
||||
import { ComposeContextProvider } from "foxact/compose-context-provider";
|
||||
import React from "react";
|
||||
import { createRoot } from "react-dom/client";
|
||||
import { RouterProvider } from "react-router";
|
||||
import { MihomoWebSocket } from "tauri-plugin-mihomo-api";
|
||||
@@ -56,17 +55,15 @@ const initializeApp = () => {
|
||||
|
||||
const root = createRoot(container);
|
||||
root.render(
|
||||
<React.StrictMode>
|
||||
<ComposeContextProvider contexts={contexts}>
|
||||
<BaseErrorBoundary>
|
||||
<WindowProvider>
|
||||
<AppDataProvider>
|
||||
<RouterProvider router={router} />
|
||||
</AppDataProvider>
|
||||
</WindowProvider>
|
||||
</BaseErrorBoundary>
|
||||
</ComposeContextProvider>
|
||||
</React.StrictMode>,
|
||||
<ComposeContextProvider contexts={contexts}>
|
||||
<BaseErrorBoundary>
|
||||
<WindowProvider>
|
||||
<AppDataProvider>
|
||||
<RouterProvider router={router} />
|
||||
</AppDataProvider>
|
||||
</WindowProvider>
|
||||
</BaseErrorBoundary>
|
||||
</ComposeContextProvider>,
|
||||
);
|
||||
};
|
||||
|
||||
|
||||
@@ -25,6 +25,7 @@ import {
|
||||
} from "@mui/material";
|
||||
import dayjs from "dayjs";
|
||||
import relativeTime from "dayjs/plugin/relativeTime";
|
||||
import type { CSSProperties } from "react";
|
||||
import {
|
||||
useCallback,
|
||||
useEffect,
|
||||
@@ -33,7 +34,6 @@ import {
|
||||
useRef,
|
||||
useState,
|
||||
} from "react";
|
||||
import type { CSSProperties } from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { Outlet, useNavigate } from "react-router";
|
||||
import { SWRConfig } from "swr";
|
||||
|
||||
Reference in New Issue
Block a user