upgrade-js-deps
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseYour task
你的任务
Upgrade all JavaScript dependencies and verify nothing is broken.
升级所有JavaScript依赖并验证没有功能损坏。
Step 1: Check for available upgrades
步骤1:检查可用更新
Run to see what upgrades are available. Review the output and
present the list to the user.
npx npm-check-updates运行查看有哪些可用更新。查看输出结果并将列表展示给用户。
npx npm-check-updatesStep 2: Update package.json
步骤2:更新package.json
Run to update with the new versions.
npx npm-check-updates -upackage.json运行,将新版本更新到中。
npx npm-check-updates -upackage.jsonStep 3: Install updated dependencies
步骤3:安装更新后的依赖
Run to install the upgraded dependencies and update .
make npm-installpackage-lock.json运行来安装升级后的依赖并更新。
make npm-installpackage-lock.jsonStep 4: Run post-upgrade checks
步骤4:运行升级后检查
Run these checks sequentially, stopping if any step fails:
- TypeScript type checking: Run and report any new type errors.
make npm-type-check - Build: Run to verify the production build still works.
make npm-build - Tests: Run to verify the test suite still passes.
make test
按顺序运行以下检查,如果任何步骤失败则停止:
- TypeScript类型检查:运行并报告任何新出现的类型错误。
make npm-type-check - 构建:运行以验证生产构建仍能正常工作。
make npm-build - 测试:运行以验证测试套件仍能通过。
make test
Step 5: Summarize and commit
步骤5:总结并提交
Summarize what was done:
- Which packages were upgraded (notable version changes)
- Whether any type errors were introduced
- Whether the build succeeded
- Whether all tests passed
- Any issues that need manual attention
If there were failures, present the issues and ask how the user wants to proceed.
If everything passed, ask the user if they'd like to commit the changes. If yes, commit
using the skill.
/commit总结已完成的操作:
- 哪些包被升级了(值得注意的版本变更)
- 是否引入了任何类型错误
- 构建是否成功
- 所有测试是否通过
- 任何需要手动处理的问题
如果有失败情况,展示问题并询问用户希望如何继续。
如果所有步骤都通过,询问用户是否要提交更改。如果用户同意,使用技能进行提交。
/commit