egoist / tsup

The simplest and fastest way to bundle your TypeScript libraries.
https://tsup.egoist.dev
MIT License
8.49k stars 209 forks source link

Add onDTSSuccess option #1024

Open NickBolles opened 8 months ago

NickBolles commented 8 months ago

Fixes #700

codesandbox[bot] commented 8 months ago

Review or Edit in CodeSandbox

Open the branch in Web EditorVS CodeInsiders
Open Preview

vercel[bot] commented 8 months ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
tsup ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 17, 2023 3:54am
NickBolles commented 7 months ago

@toteto i think my comment on the linked fixed issue is a pretty compelling use case:

We're using onsuccess to call yalc publish for a dev command. We see the JS code get updated in the consuming app, but not the typings until the next build. calling onSuccess again when dts is complete, or having another handler for dts completion would be helpful for this usecase too. https://github.com/egoist/tsup/issues/700#issuecomment-1765593865

maybe this pr doesnt completely fix #700 though because there are other use cases