Skip to content
This repository has been archived by the owner on Jul 2, 2021. It is now read-only.

Package installs various fetch libraries #33

Closed
middle-way-approach opened this issue Jul 23, 2018 · 1 comment
Closed

Package installs various fetch libraries #33

middle-way-approach opened this issue Jul 23, 2018 · 1 comment

Comments

@middle-way-approach
Copy link

Steps to reproduce

  1. npm init
  2. npm install fbemitter
  3. See isomorphic-fetch, node-fetch, whatwg-fetch in the node_modules folder
    node_modules

This looks smelly to me. Why does the emitter needs fetch libraries?

@zpao
Copy link
Contributor

zpao commented Jul 25, 2018

This is the flattened dependency tree. fbemitter requires fbjs which requires isomorphic-fetch which requires node-fetch and whatwg-fetch.

ProTip: You can run npm ls in the future to determine what the dependency tree look like.

/p/t/emittertest ❯ npm ls
emittertest@1.0.0 /private/tmp/emittertest
└─┬ fbemitter@2.1.1
  └─┬ fbjs@0.8.17
    ├── core-js@1.2.7
    ├─┬ isomorphic-fetch@2.2.1
    │ ├─┬ node-fetch@1.7.3
    │ │ ├─┬ encoding@0.1.12
    │ │ │ └─┬ iconv-lite@0.4.23
    │ │ │   └── safer-buffer@2.1.2
    │ │ └── is-stream@1.1.0
    │ └── whatwg-fetch@2.0.4
    ├─┬ loose-envify@1.4.0
    │ └── js-tokens@4.0.0
    ├── object-assign@4.1.1
    ├─┬ promise@7.3.1
    │ └── asap@2.0.6
    ├── setimmediate@1.0.5
    └── ua-parser-js@0.7.18

@zpao zpao closed this as completed Jul 25, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants