perf: add prefetch all api when build container and incrase light house score

This commit is contained in:
2026-07-07 20:39:46 +07:00 Unverified
parent 0c806410eb
commit 8af12db64b
4 changed files with 19 additions and 0 deletions
+10
View File
@@ -0,0 +1,10 @@
export async function register() {
if (process.env.NEXT_RUNTIME === "nodejs") {
try {
const { getFollowerCounts } = await import("./lib/followers");
await getFollowerCounts();
} catch (error) {
console.error("[Instrumentation] Failed to warm up cache:", error);
}
}
}