ComfyBox
ComfyBox copied to clipboard
Global event bus
Some events already work in a "global" fashion like the default queue prompt button and the beforeQueued/afterQueued event. So it makes sense to have users create their own global events that are forwarded throughout the graph.
I wonder how this would work however. There would be some global state with a dict of Record<EventName, LGraphNode[]> somewhere I think. When onAction is called each node on the bus is triggered in sequence.