mirror of
https://github.com/langgenius/dify.git
synced 2026-03-01 22:08:41 +08:00
Apply "defer state reads to usage point" principle to fix real anti-patterns where state properties were subscribed but only used in callbacks, not in JSX render: - env-panel/variable-modal.tsx: envList, envSecrets -> getState() - chat-variable-panel/variable-modal.tsx: varList -> getState() - publish-as-knowledge-pipeline-modal.tsx: knowledgeName, knowledgeIcon -> lazy useState initialization with getState() - rag-pipeline-header/index.tsx: remove unused showDebugAndPreviewPanel subscription and dead code cleanup