Hacker News new | ask | show | jobs
by stevenpetryk 717 days ago
That can be nice, but do keep in mind that shipping more files leads to a larger tarball downloaded from npm.
1 comments

Of course. A few more kilobytes is a good tradeoff for debuggability and the ability to read the original code during development. Web apps that get bundled won't include it, ESM web apps won't request them, and if a server side application is sensitive to deployment size, it's trivial to remove source files from all dependencies during build. As an application developer I'd much rather an upstream package provide it and let me strip it out than the opposite.