Skip to content
This repository has been archived by the owner. It is now read-only.

How to quickly update project dependencies of an outdated project #571

Closed
vibhanshuc opened this issue Feb 4, 2019 · 4 comments
Closed

How to quickly update project dependencies of an outdated project #571

vibhanshuc opened this issue Feb 4, 2019 · 4 comments

Comments

@vibhanshuc
Copy link

@vibhanshuc vibhanshuc commented Feb 4, 2019

If I have a react project which has a lot of devDependencies and dependencies and I haven't worked on that project for a while.
Naturally these dependencies will receive some updated version. Now when I have to start working on the project, I would want to use updated versions of the dependencies. I have to first check which all dependencies have received updates and then go on to check which one have received what changes by going into the CHANGELOG of each dependency's github repository. Then we have to make changes in our code wherever applicable.

Is there some other way using which can help me make this process quick.

Consider this react project as standalone application rather than a library.

@artivilla
Copy link

@artivilla artivilla commented Feb 18, 2019

Integrations like https://greenkeeper.io/ help keep your dependencies updated if a new version is published by the author rather than running npm outdated every few months. With some minimal setup, provided you have tests in place this is much easier to maintain than going and updating 20+ dependencies.

Given minor and patch updates can still cause havoc, I'd still be cautious.

You can also start with udpating only patch/minor versions and test if your application works. If so then, go through the docs for major breaking updates and make the necessary changes.

Obviously, this is Kent's ama so I'll let him answer.

@elkevinwolf
Copy link

@elkevinwolf elkevinwolf commented Mar 6, 2019

I can recommend running yarn upgrade-interactive --latest, since it will let me selectively upgrade packages and also persist to package.json and yarn.lock files.

@Apidcloud
Copy link

@Apidcloud Apidcloud commented Mar 10, 2019

I also use yarn, but if you are using npmyou can use something similar, npm-upgrade: https://www.npmjs.com/package/npm-upgrade

@kentcdodds
Copy link
Owner

@kentcdodds kentcdodds commented Mar 22, 2019

I answered this today on 3 minutes with Kent :) https://www.briefs.fm/3-minutes-with-kent/101

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants