Skip to content

Conversation

@boneskull
Copy link
Member

@boneskull boneskull commented Aug 1, 2025

This updates the mermaid-deptree script to include the state of a package as a production, development, optional, peer, or optional-peer dependency via link styling and text.

The output now also:

  • wraps the output in a Markdown fenced code block
  • includes front-matter config for appropriate styling
  • includes a word-wrapping fix

Example output:

---
config:
  themeVariables:
    fontFamily: "Fira Mono,Menlo,Consolas,Liberation Mono,monospace"
---
graph TD
  webpackish-app--> |"`_dev_`"| jorts-folder
  webpackish-app--> |"`_dev_`"| pantspack
  jorts-folder--- |"`_peer_`"| pantspack
  pantspack==> pantspack-folder-runner
classDef default white-space:nowrap
Loading

Also updates the README.md for the fixtures-dynamic-ancestor in @endo/compartment-mapper with a generated graph.

I guess there's no example of "optional peer" in that example. oops

This updates the `mermaid-deptree` script to include the state of a package as a production, development, optional, peer, or optional-peer dependency via link styling and text.

The output now also:

- wraps the output in a Markdown fenced code block
- includes front-matter config for appropriate styling
- includes a word-wrapping fix

Example output:

```mermaid
---
config:
  themeVariables:
    fontFamily: "Fira Mono,Menlo,Consolas,Liberation Mono,monospace"
---
graph TD
  webpackish-app--> |"`_dev_`"| jorts-folder
  webpackish-app--> |"`_dev_`"| pantspack
  jorts-folder--- |"`_peer_`"| pantspack
  pantspack==> pantspack-folder-runner
classDef default white-space:nowrap
```
@boneskull boneskull requested review from kriskowal and naugtur August 1, 2025 22:03
@boneskull boneskull self-assigned this Aug 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants