This commit is contained in:
Timothy Jaeryang Baek
2026-04-11 16:55:20 -06:00
parent 674695918e
commit 09f6d7ba57
3 changed files with 53 additions and 6 deletions
+6 -4
View File
@@ -47,8 +47,8 @@
let page = 1;
// Debounce only query changes
$: if (query !== undefined) {
// Debounce only query changes (gate behind loaded to prevent double-fetch on mount)
$: if (loaded && query !== undefined) {
loading = true;
clearTimeout(searchDebounceTimer);
searchDebounceTimer = setTimeout(() => {
@@ -57,8 +57,8 @@
}, 300);
}
// Immediate response to page/filter changes
$: if (page && statusFilter !== undefined) {
// Immediate response to page/filter changes (gate behind loaded)
$: if (loaded && page && statusFilter !== undefined) {
getAutomationList();
}
@@ -171,6 +171,8 @@
}
loaded = true;
// Explicit initial fetch — reactive blocks will handle subsequent changes
await getAutomationList();
return () => {
clearTimeout(searchDebounceTimer);