One detail that has always bugged me about publishing a package to NPM is how build output paths like dist/ can leak into the public API.
Turns out, npm publish can do it, but to make it work seamlessly in a real-world project, you need a few extra pieces in place. Let me walk you through how it works.