summaryrefslogtreecommitdiff
path: root/deps/npm/doc/misc/npm-developers.md
diff options
context:
space:
mode:
Diffstat (limited to 'deps/npm/doc/misc/npm-developers.md')
-rw-r--r--deps/npm/doc/misc/npm-developers.md13
1 files changed, 13 insertions, 0 deletions
diff --git a/deps/npm/doc/misc/npm-developers.md b/deps/npm/doc/misc/npm-developers.md
index e8df1ed7b9..2f54b98fb9 100644
--- a/deps/npm/doc/misc/npm-developers.md
+++ b/deps/npm/doc/misc/npm-developers.md
@@ -140,6 +140,19 @@ The following paths and files are never ignored, so adding them to
* `CHANGELOG` (and its variants)
* `LICENSE` / `LICENCE`
+If, given the structure of your project, you find `.npmignore` to be a
+maintenance headache, you might instead try populating the `files`
+property of `package.json`, which is an array of file or directory names
+that should be included in your package. Sometimes a whitelist is easier
+to manage than a blacklist.
+
+### Testing whether your `.npmignore` or `files` config works
+
+If you want to double check that your package will include only the files
+you intend it to when published, you can run the `npm pack` command locally
+which will generate a tarball in the working directory, the same way it
+does for publishing.
+
## Link Packages
`npm link` is designed to install a development package and see the