Upgrade npm dependency version
MSALUpgrades the version constraint of matching npm dependencies in package.json and regenerates the lock file natively, without executing the package manager. Matching is by exact package name or glob pattern. A version range is replaced when it admits a version below the new range's lowest; one that already starts at or above it is left, and so is a peerDependencies range that admits every version the new one does. A catalog: reference is upgraded in its catalog entry by the same rule, and any other value is left as it is. Not safe to use as a precondition: consults the package registry over the network and publishes per-project state shared with other dependency recipes.
org. openrewrite. javascript. UpgradeDependencyVersionRequired
The new version constraint to set on matching dependencies.
Optional
Exact package name to match. Mutually exclusive with packagePattern; at least one is required.
Glob pattern matching package names (e.g., @types/*). Mutually exclusive with packageName; at least one is required.
mod run . --recipe= org. openrewrite. javascript. UpgradeDependencyVersion \
-P newVersion= '^5.0.0'Install it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.