-
-
Notifications
You must be signed in to change notification settings - Fork 44
Description
My CDK project has many stacks, and I would like to render individual interactive diagrams for each stack in order to host them in my web application.
Using the current options, we can either render everything into a single diagram (which quickly becomes unreadable) or loop over the stacks and render each individually, this results in a somewhat large directory per stack including assets. Rendering and storing this takes up quite some time and space.
I would want to render many diagrams in a single command, which creates the shared assets only once. Each diagram can be opened separately an reuses the shared assets. This takes up way less space and (hopefully) also increases the generation speed.
For example, adding a flag like --merge
, --bulk
or --joined
:
npx cdk-dia --rendering cytoscape-html --include stack-one stack-two --merge
Results in a directory like:
diagram /
| - icons /
| - js /
| - bundle.css
| - <stack-one>-cy-elements.json
| - <stack-one>-cy-styles.json
| - <stack-one>.html
| - <stack-two>-cy-elements.json
| - <stack-two>-cy-styles.json
| - <stack-two>.html
I can implement this if the feature seems useful. Thank you for this very useful project!