learn-a
learn-a copied to clipboard
.npmignore can contain src/
Ignoring the src folder in .npmignore reduces package size.
Someone at MS knows haha: https://github.com/Microsoft/TypeScript/blob/master/.npmignore
tsconfig.json as well, for that matter :)
Depending on the build, sometimes source-maps reference the source files, and unless you publish /src these will not work.
Yeah just chiming in here, for most libs it's best-practice to ship source code to npm too. If your codebase is massive, like Microsoft/TypeScript likely is, I can see why you'd want to avoid it.