A custom React-based visual workflow builder inspired by n8n, allowing users to create, connect, and execute custom logic flows via a drag-and-drop node system.
- ⚙️ Custom Node System – Easily extendable node architecture via
nodeTypes - 🔗 Connection-Based Flow – Drag and connect nodes to define execution order
- 🎛 Side Panel Configuration – Select a node to update its config in a dynamic form panel
- 🧩 Modular Components – Fully component-based structure using
NodeComponent,RenderFormField, and utility handlers - 💡 Execution Engine – Runs nodes sequentially based on topological ordering
- 🔄 Interactive Canvas – Drag, pan, zoom, and reset view for a smooth UX
- 🗑️ Safe Deletion – Confirm before removing nodes (supports
Deletekey) - 🧰 Custom Node Execution Logic – Defined via
NodeFunction
src/
├── components/
│ ├── nodes.js # Renders individual node components (icon, color, config)
│ └── PanelField.js # Generates dynamic config forms for selected nodes
├── util/
│ ├── util.js # Contains the logic to execute nodes in flow order
│ └── nodeArrays.js # Defines node types, schema, icons, and categories
├── N8NWorkflowPlatform.js # Main app UI: canvas, panel, and node management
└── App.js # App entry point that renders the workflow platform
- Node.js (v14 or higher)
- npm or yarn
-
Clone the repository
git clone https://github.com/berto6544-collab/2kai-workflow.git cd 2kai-workflow -
Install dependencies
npm install
-
Start the development server
npm run dev
-
Open your browser
Visit
http://localhost:5173to view the application.
Update nodeArrays.js to define a new nodeTypes entry:
{
id: 'uniqueId', // Unique identifier
name: 'Display Name', // Human-readable name
icon: IconComponent, // React icon component
color: 'tailwind-classes', // Tailwind CSS classes for styling
category: 'Category', // Grouping category
output: ['response','error'], // output response and error handling
input:['data'], // input data
}Update nodeArrays.js to define a new nodeConfiguration:
configs = {
myCustomNode: [
{
name: 'fieldName', // Field identifier
label: 'Field Label', // Display label
type: 'text|textarea|select|number', // Input type
value: '', // Default value
placeholder: 'text', // Placeholder text
required: true|false, // Validation requirement
options: [] // For select type fields
}
]
}Add your custom execution logic in the appropriate utility files to handle your new node type.
- Add Nodes: Drag nodes from the sidebar onto the canvas
- Connect Nodes: Click and drag between node connection points to create flows
- Configure Nodes: Select a node to edit its properties in the side panel
- Execute Workflow: Run your complete workflow to see results
- Manage Canvas: Use pan, zoom, and reset controls for better navigation
Node types are defined in src/util/nodeArrays.js with the following structure:
{
id: 'uniqueId', // Unique identifier
name: 'Display Name', // Human-readable name
icon: IconComponent, // React icon component
color: 'tailwind-classes', // Tailwind CSS classes for styling
category: 'Category' // Grouping category
output: ['response','error'] // output response and error handling
input:['data'] // input data
}{
name: 'fieldName', // Field identifier
label: 'Field Label', // Display label
type: 'text|textarea|select|number', // Input type
value: '', // Default value
placeholder: 'text', // Placeholder text
required: true|false, // Validation requirement
options: [] // For select type fields
}- Components: Reusable React components for nodes and forms
- Utilities: Core logic for node execution and configuration
- Main Platform: Primary application interface and state management
main.jsx: Main application componentnodes.js: Individual node rendering logicPanelField.js: Dynamic form field generationutil.js: Workflow execution enginenodeArrays.js: Node definitions and configurations
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
MIT License © Roberto D'Amico
If you encounter any issues or have suggestions, please open an issue on GitHub.
- Inspired by n8n workflow automation platform
- Built with React and modern web technologies
- Thanks to all contributors and users
Made with ❤️ by Roberto D'Amico

