-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Contentstack package depends on isomorphic-fetch, doesn't use it #99
Comments
For reference this was detectable (and problematic) since node-fetch was resolved (again implicitly) to a version which was installed by another package in our monorepo. Unlike the node-fetch v2 dependency declared by isomorphic-fetch, the node-fetch v3 dependency which was then resolved (implicitly because it was undeclared by
|
For reference a proven version of |
Thank you for bringing this to our attention @cefn. We greatly appreciate your effort in reporting the issue. Our team is currently investigating the matter and looking into the details provided. |
Any updates on this issue? |
Please make this package stable. |
HI @cefn we will require some more time to check this and we will update you as soon as possible |
In our test suite (running in node) it seems depending on
contentstack
creates a broken package dependency situation.At
contentstack-javascript/src/runtime/node/http.js
Line 2 in 290cda7
contentstack
package importsnode-fetch
. However, it doesn't declarenode-fetch
among its dependencies.The "contentstack" package correctly declares
isomorphic-fetch
among its dependencies. Theisomorphic-fetch
project allows packages to be defined which are neither node- or browser- specific, with theisomorphic-fetch
package resolving to the appropriate packages at runtime.However, because
contentstack
incorrectly importsnode-fetch
instead ofisomorphic-fetch
this forces projects to explicitly install node-fetch to prevent runtime errors when testing in node. This defeats the purpose of isomorphism, meaning that packages which are ONLY intended for client-side deployment end up needing anode-fetch
dependency which makes no sense.The text was updated successfully, but these errors were encountered: