meshed.scrap.misc_utils#
Misc utils
Functions
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Output mermaid code with nodes packed into a single node. |
- meshed.scrap.misc_utils.mermaid_pack_nodes(mermaid_code, nodes, packed_node_name=None, *, arrow='-->')[source]#
Output mermaid code with nodes packed into a single node.
- Return type:
>>> mermaid_code = ''' ... graph TD ... A --> B ... B --> C ... A --> D ... D --> E ... E --> C ... ''' >>> >>> >>> print(mermaid_pack_nodes(mermaid_code, ['B', 'C', 'E'], 'BCE')) graph TD A -->BCE A --> D D -->BCE