Dependency Upgrade One-by-One
Upgrade a single outdated package per iteration, fix breakages, and commit — safer than bulk npm update.
// parameters
// run_this_loop
Copy the kickoff into your agent first. The blueprint below explains how the loop evaluates progress and when it should stop.
Use loop copies the kickoff prompt. Share copies the loop link. Open in Cursor / Claude only pre-fill that prompt — they do not install hook files. Download loop saves the loop as dependency-upgrade-one-by-one.md.
Start the "Dependency Upgrade One-by-One" loop.
Goal: critical outdated deps are upgraded with green tests
Max iterations: 15
Between iterations run: npm outdated && npm test && npm run build
Exit when: npm outdated shows no critical packages left or user stops
Step 1: Pick one outdated package, upgrade it, fix breakages, commit, and stop. One package per iteration.
Self-pace this loop. After each iteration, run the check command, read the output, and only continue if the exit condition is not met. Stop when the exit condition passes or max iterations is reached. Give a short status update each pass.// blueprint
The loop contract: target outcome, execution sequence, checks, stopping condition, and safety constraints.
critical outdated deps are upgraded with green tests
// loop_sequence
Trigger
Manual start
Actions block
Feedback gate
Evaluate: state progress
Run the check, read the output, then decide whether the loop is complete.
Check failed
Repeat actions with the latest feedback.
Success
No outdated production dependencies remain (or user stops)
// steps
- 1Pick one package
Run npm outdated. Pick the highest-impact outdated package (one only). Note its current and target version.
npm outdated - 2Upgrade and fix
Upgrade that single package. Fix type errors, API changes, and test failures caused by the bump.
npm test && npm run build - 3Commit bump
Commit with message like chore(deps): bump <package> to <version>.
Docs Sync After Edits
After code changes, find affected docs and update README, API references, and inline comments to match.
Dependency Audit Weekly
Weekly loop to check outdated dependencies, propose safe upgrades, and open a summary.
Knip Until Clean
Find and remove dead exports, unused files, and orphan dependencies — loop until knip reports clean.