fix(boards): replace global cache with React cache() per-request dedup

The unstable_cache approach bypassed throwIfActionForbiddenAsync and
dropped user-specific data (permissions, collapse states). Use React
cache() to deduplicate getInitialBoard within a single request instead,
preserving auth checks and all user data while reducing DB calls from
9 to 3 per board page load.
This commit is contained in:
Thomas Camlong committed 2026-05-25 11:01:07 +02:00
1 parent 689da2fb91
commit 884fde245b
11 files changed
+10 -145

No files matched your search

+1 -2
View File
@@ -10,8 +10,7 @@
"./server": "./src/server.ts",
"./websocket": "./src/websocket.ts",
"./shared": "./src/shared.ts",
"./open-api": "./src/open-api.ts",
"./router/board": "./src/router/board-exports.ts"
"./open-api": "./src/open-api.ts"
},
"main": "./index.ts",
"types": "./index.ts",