import React, { useContext } from 'react'; import { Handle, Position } from 'reactflow'; import { WorkflowContext } from './App'; // Import context from App.js import './RunNode.css'; const RunNode = ({ data, isConnectable, id }) => { const { handleRunFromNode, isRunning } = useContext(WorkflowContext); // Get the specific run function and running state // Run only this specific workflow branch const runThisWorkflow = () => { handleRunFromNode(id); }; return (
Connect this node to the start of your flow and click the button to begin.