How to bundle a typescript library and publish with npm?

Read this

https://cameronnokes.com/blog/the-30-second-guide-to-publishing-a-typescript-package-to-npm/

https://dev.to/0xkoji/create-a-npm-package-template-with-typescript-and-tsup-328n

A: Use tsup

TODO: try this for npm publish https://github.com/sindresorhus/np