mirror of
https://github.com/langgenius/dify.git
synced 2026-05-13 06:03:15 -04:00
Use useRef for batchUpload and emitTreeUpdate to remove unstable dependencies from useCallback, preventing unnecessary memo invalidation on all 16 TemplateCard components. Wrap filtered list in useMemo and replace && conditional with ternary for rendering safety.