(type: NodeType)
| 24 | }; |
| 25 | |
| 26 | export const getExecutor = (type: NodeType): NodeExecutor => { |
| 27 | const executor = executorRegistry[type]; |
| 28 | if (!executor) { |
| 29 | throw new Error(`No executor found for node type: ${type}`); |
| 30 | } |
| 31 | |
| 32 | return executor; |
| 33 | }; |