This repository has been archived by the owner on Jan 18, 2024. It is now read-only.
How to downgrade all NPM packages to compatible versions after upgrading all dependencies? #4528
Unanswered
martin-braun
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Disclaimer: I also asked this question on the forum, because I don't know where I should rather ask the question.
I'm looking for a way to upgrade all NPM packages in one command, incl. major versions and updating the package.json. This should also upgrade expo using the CLI, but it should make sure that my packages stay compatible.
Simply running
expo-cli upgrade
is not sufficient, because I might have other NPM packages that won't be upgraded in this step.I installed npm-check-updates to forcefully upgrade all packages (incl.
expo-cli
) and update the contents of the package.json simultaneously. Then I try to upgrade expo in the hope that it downgrades all packages that are too high, again, but it does not.package.json
Running
npm run upgrade
causes:This is, because
npm-check-updates -u
will upgradereact
to18.2.0
, although the current expo SDK supports on18.0.0
.According to @brentvatne (ref) and @bsgbryan (ref)
expo-cli upgrade
(formerlyexpo upgrade
) should indeed downgrade my packages and it should update the contents of the package.json in that process, right?I know, that my script will most likely cause issues in my code. The command is not designed to run any now and then, but only to port the app to the most recent dependencies possible.
Here is my full package.json:
Beta Was this translation helpful? Give feedback.
All reactions