feat: add single tool schema rendering

This commit is contained in:
2026-09-04 16:12:43 +05:00
parent d1a386f92f
commit 1c746299c9
6 changed files with 550 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
export function debounce(
fn: () => void,
ms: number,
): { (): void; cancel: () => void } {
let timer: ReturnType<typeof setTimeout> | undefined;
const debounced = () => {
if (timer !== undefined) clearTimeout(timer);
timer = setTimeout(() => fn(), ms);
};
debounced.cancel = () => {
if (timer !== undefined) clearTimeout(timer);
};
return debounced;
}