The best way to control Claude Code, Codex and more from any computer or phone
Mirrored from https://github.com/Camo67/t3code.git
Synced Nov 23, 06:45 UTC
perf(web): the CSV table preview compiles without manual memoization (#20680)
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Julius Marminge committed
Oct 16, 2026 at 21:54 UTC
d859445528aa951c383644d0afcd5d4a3ce0f006
1 file changed
+1
-5
apps/web/src/components/files/DelimitedTablePreview.tsx
+1
-5
@@ -1,6 +1,5 @@
1
/* oxlint-disable react/no-array-index-key -- Table rows and columns have stable positions and may contain identical values. */
2
import { parseDelimitedPreview } from "@t3tools/shared/delimitedPreview";
3
-import { useMemo } from "react";
3
4
import { FileSurfaceNotice } from "./fileSurfaceChrome";
5
@@ -9,10 +8,7 @@ export function DelimitedTablePreview(props: {
8
readonly text: string;
9
readonly delimiter: "," | "\t";
10
}) {
12
- const table = useMemo(
13
- () => parseDelimitedPreview(props.text, props.delimiter),
14
- [props.text, props.delimiter],
15
- );
11
+ const table = parseDelimitedPreview(props.text, props.delimiter);
12
const [header, ...body] = table.rows;
13
return (
14
<div className="flex min-h-0 flex-1 flex-col">