🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.
TypeScript agentagent-collaborationagent-harnessloop-engineeringmcppersonal-assistantproactive-agentskillssuper-agenttask-management
📝 docs(bot): Auto sync agents & plugin to readme
lobehubbot7461d4e48676
diff --git a/src/app/[variants]/desktopRouter.config.tsx b/src/app/[variants]/desktopRouter.config.tsxindex 374d1fff598..07eef4195f5 100644--- a/src/app/[variants]/desktopRouter.config.tsx+++ b/src/app/[variants]/desktopRouter.config.tsx@@ -1,7 +1,7 @@'use client';import { useEffect } from 'react';-import { createBrowserRouter, redirect, type LoaderFunction, useNavigate } from 'react-router-dom';+import { type LoaderFunction, createBrowserRouter, redirect, useNavigate } from 'react-router-dom';import Loading from '@/components/Loading/BrandTextLoading';import { useGlobalStore } from '@/store/global';@@ -65,7 +65,6 @@ export const createDesktopRouter = (locale: Locales) =>createBrowserRouter([{HydrateFallback: () => <Loading />,- loader: hydrationGateLoader,children: [// Chat routes{@@ -376,6 +375,7 @@ export const createDesktopRouter = (locale: Locales) =>},],element: <RootLayout locale={locale} />,+ loader: hydrationGateLoader,path: '/',},]);diff --git a/src/app/[variants]/mobileRouter.config.tsx b/src/app/[variants]/mobileRouter.config.tsxindex f60dd41e0e2..fffac5dccc1 100644--- a/src/app/[variants]/mobileRouter.config.tsx+++ b/src/app/[variants]/mobileRouter.config.tsx@@ -1,7 +1,7 @@'use client';import { useEffect } from 'react';-import { redirect, createBrowserRouter, type LoaderFunction, useNavigate } from 'react-router-dom';+import { type LoaderFunction, createBrowserRouter, redirect, useNavigate } from 'react-router-dom';import Loading from '@/components/Loading/BrandTextLoading';import { useGlobalStore } from '@/store/global';@@ -63,7 +63,6 @@ export const createMobileRouter = (locale: Locales) =>createBrowserRouter([{HydrateFallback: () => <Loading />,- loader: hydrationGateLoader,children: [// Chat routes{@@ -361,13 +360,15 @@ export const createMobileRouter = (locale: Locales) =>})),},{- children: [{- lazy: () =>- import('./(main)/(mobile)/me/profile').then((m) => ({- Component: m.default,- })),- path: 'profile',- }],+ children: [+ {+ lazy: () =>+ import('./(main)/(mobile)/me/profile').then((m) => ({+ Component: m.default,+ })),+ path: 'profile',+ },+ ],lazy: () =>import('./(main)/(mobile)/me/profile/layout').then((m) => ({Component: m.default,@@ -387,7 +388,7 @@ export const createMobileRouter = (locale: Locales) =>import('./(main)/(mobile)/me/settings/layout').then((m) => ({Component: m.default,})),- }+ },],path: 'me',},@@ -405,6 +406,7 @@ export const createMobileRouter = (locale: Locales) =>},],element: <RootLayout locale={locale} />,+ loader: hydrationGateLoader,path: '/',},]);diff --git a/src/components/BootErrorBoundary/index.tsx b/src/components/BootErrorBoundary/index.tsxindex 2b2b98f6f49..e73370c68b9 100644--- a/src/components/BootErrorBoundary/index.tsx+++ b/src/components/BootErrorBoundary/index.tsx@@ -80,12 +80,16 @@ class BootErrorBoundary extends Component<BootErrorBoundaryProps, BootErrorBoundif (attempts >= maxReloads) {// eslint-disable-next-line no-console- console.warn('BootErrorBoundary reached max reload attempts', { attempts, maxReloads, href });+ console.warn('BootErrorBoundary reached max reload attempts', {+ attempts,+ href,+ maxReloads,+ });return false;}// eslint-disable-next-line no-console- console.info('BootErrorBoundary forcing hard reload', { attempts, maxReloads, href });+ console.info('BootErrorBoundary forcing hard reload', { attempts, href, maxReloads });window.sessionStorage.setItem(RELOAD_SESSION_KEY, String(attempts + 1));} catch (error) {// If sessionStorage is unavailable, we still attempt a reload once.diff --git a/src/layout/GlobalProvider/StoreInitialization.tsx b/src/layout/GlobalProvider/StoreInitialization.tsxindex 7c7c0831415..b713dea03f0 100644--- a/src/layout/GlobalProvider/StoreInitialization.tsx+++ b/src/layout/GlobalProvider/StoreInitialization.tsx@@ -63,6 +63,11 @@ const StoreInitialization = memo(() => {// init user stateuseInitUserState(isLoginOnInit, serverConfig, {+ onError: () => {+ // 即使失败也要设置标志,避免应用卡住+ useGlobalStore.setState({ isAppHydrated: true });+ console.warn('[Hydration] Client state initialization failed.');+ },onSuccess: (state) => {// 设置水合完成标志useGlobalStore.setState({ isAppHydrated: true });@@ -72,11 +77,6 @@ const StoreInitialization = memo(() => {router.push('/onboard');}},- onError: () => {- // 即使失败也要设置标志,避免应用卡住- useGlobalStore.setState({ isAppHydrated: true });- console.warn('[Hydration] Client state initialization failed.');- },});const useStoreUpdater = createStoreUpdater(useGlobalStore);