There is a really nice initiative called e18e, whose goal is to clean up, optimize, and speed up libraries and their dependency trees in the node ecosystem. Given that this project is ESM-only and requires Node.js >=22.18.0, we could replace some things with native Node.js APIs, better alternatives, etc. to make hey-api safer and lighter.
Quick replacements (i'll open PRs for those):
Harder, so you probably don't have to do any of these:
Tip: I really recommend this site: https://npmgraph.js.org/?q=%40hey-api%2Fopenapi-ts, so you can visualise your dependency tree.
There is a really nice initiative called e18e, whose goal is to clean up, optimize, and speed up libraries and their dependency trees in the node ecosystem. Given that this project is ESM-only and requires Node.js >=22.18.0, we could replace some things with native Node.js APIs, better alternatives, etc. to make
hey-apisafer and lighter.Quick replacements (i'll open PRs for those):
ansi-colorscould be replaced with the native Node.js APIResolved by: refactor: replace ansi-colors and color-support with native styleText #4291
color-supportcould be replaced with the native Node.js APIResolved by: refactor: replace ansi-colors and color-support with native styleText #4291
semvercould be replaced withverkit- Replacesemverwithverkite18e/ecosystem-issues#277is-yaml- https://e18e.dev/docs/replacements/js-yamlHarder, so you probably don't have to do any of these:
open- users don't need this dependency most of the time. It could be moved to peer dependencies, and ifopenis not detected, you could just print the URLcross-spawn- make it an optional dependency, since you might not need a formatter@jsdevtools/onoTip: I really recommend this site: https://npmgraph.js.org/?q=%40hey-api%2Fopenapi-ts, so you can visualise your dependency tree.