From d9682059584648682964f87097ccc2ed6d8258ac Mon Sep 17 00:00:00 2001 From: Julius Marminge <51714798+juliusmarminge@users.noreply.github.com> Date: Fri, 16 Oct 2026 21:37:34 -0700 Subject: [PATCH] perf(web): the thread context drop hook compiles with the React Compiler Co-Authored-By: Claude Opus 5.5 --- apps/web/src/components/chat/threadContextDrag.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/apps/web/src/components/chat/threadContextDrag.ts b/apps/web/src/components/chat/threadContextDrag.ts index 549aa4ab2f3a..040e5a920e25 100644 --- a/apps/web/src/components/chat/threadContextDrag.ts +++ b/apps/web/src/components/chat/threadContextDrag.ts @@ -21,7 +21,12 @@ export function useThreadContextDrop( active = false; target.removeEventListener(THREAD_CONTEXT_DROP_EVENT, listener); }; - }, [environmentId, targetKey, targetRef]); + }, [ + // oxlint-disable-next-line react/exhaustive-effect-dependencies -- A new environment or target ends the previous listener, so isActive reports false to drops still in flight for it. + environmentId, + targetKey, + targetRef, + ]); } const DROP_TARGET_ATTRIBUTE = "data-thread-context-drop";