Yes, you can use Yarn or NPM to edit your package.json.
yarn upgrade [package | package@tag | package@version | @scope/]... [--ignore-engines] [--pattern]
Something like:
yarn upgrade react@^16.0.0
Then I'd see what warns or errors out and then run yarn upgrade [package]
. No need to edit the file manually. Can do everything from the CLI.
Or just run yarn upgrade
to update all packages to latest, probably a bad idea for a large project. APIs may change, things may break.
Alternatively, with NPM run npm outdated
to see what packages will be affected. Then
npm update
https://yarnpkg.com/lang/en/docs/cli/upgrade/
https://docs.npmjs.com/getting-started/updating-local-packages