Open source alternative to Semrush and Ahrefs
TypeScript backlink-analysisgoogle-search-console-mcpkeyword-researchmcpseoseo-agentseo-auditseo-automationseo-skillsseo-toolssite-audit
Stop Rank Tracking freezing on Configure, Add Keywords, and selection (EVE-384) (#831)
Ben Senescu377f978886b2
diff --git a/src/client/features/rank-tracking/RankTrackingTable.tsx b/src/client/features/rank-tracking/RankTrackingTable.tsxindex d4968ec0..bc3de4e7 100644--- a/src/client/features/rank-tracking/RankTrackingTable.tsx+++ b/src/client/features/rank-tracking/RankTrackingTable.tsx@@ -1,4 +1,4 @@-import { useCallback, useRef, useState } from "react";+import { useCallback, useMemo, useRef, useState } from "react";import { toast } from "sonner";import { FileDown, Plus, Sheet, Trash2 } from "lucide-react";import { ConfirmDialog } from "@/client/components/ConfirmDialog";@@ -86,7 +86,12 @@ export function RankTrackingTable({});// The pinned column sorts first and stays out of the sorting the page owns.- const tableSorting = [{ id: PINNED_COLUMN_ID, desc: false }, ...sorting];+ // Keep sorting stable across the table's own state updates, which otherwise+ // recompute sorted rows and queue another pagination reset on every render.+ const tableSorting = useMemo(+ () => [{ id: PINNED_COLUMN_ID, desc: false }, ...sorting],+ [sorting],+ );const table = useDataTable({data: rows,columns,