Skip to content

Commit 2c4b5cf

Browse files
committed
remove: problematic cache logic.
1 parent 218be58 commit 2c4b5cf

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

v2/pink-sb/src/lib/spreadsheet/Root.svelte

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@
6161
6262
let dragManager: DragManager;
6363
const dispatch = createEventDispatcher();
64-
const columnCache = new Map<string, number>();
6564
6665
$: if (columns) {
6766
// needs to be initialized
@@ -168,11 +167,7 @@
168167
}
169168
170169
function updateCells(columnId: string, newWidth: number) {
171-
let index = columnCache.get(columnId);
172-
if (index === undefined) {
173-
index = columns.findIndex((col) => col.id === columnId);
174-
if (index !== -1) columnCache.set(columnId, index);
175-
}
170+
let index = columns.findIndex((col) => col.id === columnId);
176171
if (index === -1) return;
177172
178173
const col = columns[index];

0 commit comments

Comments
 (0)