Skip to content

Commit 05e5dac

Browse files
perf(web): main app navigation compiles without manual memoization
Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent 70d60e0 commit 05e5dac

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

‎apps/web/reactCompiledFiles.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,4 +96,5 @@ export const REACT_COMPILED_FILES = [
9696
"apps/web/src/components/pullRequest/PullRequestDetailPanel.tsx",
9797
"apps/web/src/components/ThreadTerminalDrawer.tsx",
9898
"apps/web/src/components/settings/SettingsPanels.tsx",
99+
"apps/web/src/components/sidebar/mainAppLocation.ts",
99100
] as const;

‎apps/web/src/components/sidebar/mainAppLocation.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { useLocation, useNavigate } from "@tanstack/react-router";
2-
import { useCallback, useEffect } from "react";
2+
import { useEffect } from "react";
33

44
export function isSidebarUtilityPage(pathname: string) {
55
return (
@@ -25,5 +25,5 @@ export function MainAppLocationTracker() {
2525

2626
export function useNavigateToMainApp() {
2727
const navigate = useNavigate();
28-
return useCallback(() => navigate({ href: mainAppHref ?? "/" }), [navigate]);
28+
return () => navigate({ href: mainAppHref ?? "/" });
2929
}

0 commit comments

Comments
 (0)