aphrodite icon indicating copy to clipboard operation
aphrodite copied to clipboard

improve npmignore

Open Brianzchen opened this issue 5 years ago • 4 comments

Update .npmignore file to not publish files and dirs that aren't used by consumers. This simplified the distributed binaries but the main motivation for this change is that .flowconfig is included when aphrodite is published. Which if I browse the files within node_modules, flow server will crash because it detects multiple upstream flow configs.

@lencioni @jlfwong

Brianzchen avatar Dec 30 '20 23:12 Brianzchen

Some people will not use npm to install the package (e.g. install from GitHub url) – would that still work if src is ignored?

alii avatar Apr 21 '21 08:04 alii

People shouldn't really be using src folder directly. I mean they can but general expectation is you import via the main export which points to the built lib + /no-important in aphrodites case.

But if there's a valid use case, happy to exclude and continue to ship src

Brianzchen avatar Apr 21 '21 08:04 Brianzchen

I'm really not sure I am not knowledgable enough on the topic, was purely a question if it would still work

alii avatar Apr 21 '21 08:04 alii

I'm really not sure I am not knowledgable enough on the topic, was purely a question if it would still work

Yep should still work. npmignore is just for files to ignore during the npm publish process

Brianzchen avatar Apr 21 '21 19:04 Brianzchen