forked from node-red/node-red
-
Notifications
You must be signed in to change notification settings - Fork 0
Design: subflows
Nick O'Leary edited this page Aug 23, 2014
·
8 revisions
A subflow is a set of connected nodes that can be easily referenced and reused within a larger flow.
A subflow is represented as a single node in the workspace which can be opened up in a tab to see the underlying flow.
A subflow can be used in one of two modes: (this is tbd. Might just stick with singleton for v1)
- Singleton : only one copy of the flow exists.
- Instance : each reference to the subflow is its own copy.
- User selects some existing nodes.
- Selects 'convert to subflow' option.
- Dialog opens to name the subflow.
- Nodes are removed from workspace and replaced by a subflow node.
- Subflow node added to palette
Questions:
- how to automatically identify the input/output ports to map to
- what restrictions should be applied?
- a single, continuous flow of nodes - aside from comment nodes
- only one 'left most' node
- Double click subflow node.
- Opens in closeable tab containing the flow.
Questions:
- how to rename the flow? Via subflow sidebar tab?
- how to pick singleton/instance mode?
- Open a subflow sidebar tab that lists all subflows with usage count (cf config node tab - perhaps combine them...?)
- ...
...