0

I run npm pack inside dist folder, but it doesn't include all it's files. it just contains: package.json, ReADME.md, index.js (main).

there is no .gitignore file, and I tried to create an empty .npmignore file, but it didn't help.

I also tried to add files array to package.json.

all files in the root or subfolders (js or other files) don't included in the pack file.

Sh eldeeb
  • 1,589
  • 3
  • 18
  • 41

1 Answers1

0

I found another files property in my package.json, so adding another one has no effect, also .gitignore and .npmignore have no effect.

Sh eldeeb
  • 1,589
  • 3
  • 18
  • 41
  • 1
    `field` -> `files`? Yes, only one of those will be counted. And both `.gitignore` and `.npmignore` *reduce* the number of included files, so if the problem is having too few files of course they don't help. – jonrsharpe Jun 11 '20 at 21:17