feat: performance 1

This commit is contained in:
2026-03-12 18:01:27 +01:00
parent 4bd2f1b458
commit 923bf4bff0
18 changed files with 404 additions and 146 deletions

View File

@@ -20,7 +20,7 @@
*/
import { useContext, useEffect, useRef } from 'react'
import FlowContext from './flowContext'
import { ConnectionPathContext } from './flowContext'
export type NodeLifecyclePhase = 'idle' | 'trigger' | 'updating' | 'paused' | 'error'
@@ -53,7 +53,7 @@ export function useSyncConnectionStatus(
nodeId: string,
state: NodeConnectionStatusState
): void {
const ctx = useContext(FlowContext)
const ctx = useContext(ConnectionPathContext)
const { updating, error, paused } = state
const prevRef = useRef({ updating: false, error: false, paused: false })