perf(dev): stop saves that change nothing from restarting the dev server - #1435
Conversation
commit: |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthrough
Estimated code review effort: 3 (Moderate) | ~20 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@packages/nuxt-cli/src/dev/utils.ts`:
- Around line 110-115: Update hashFileContents to read through a file descriptor
with a buffer limited to MAX_HASHED_FILE_SIZE + 1 bytes instead of reading the
entire file via readFileSync. If the extra byte is present, return the existing
mtime-based fallback; otherwise hash only the bytes read, while preserving the
current size guard and error handling.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: b3b51cd3-ed7c-45e3-96f5-e72afa4f2997
📒 Files selected for processing (3)
packages/nuxt-cli/src/dev/utils.tspackages/nuxt-cli/test/unit/file-watcher.spec.tspackages/nuxt-cli/test/unit/per-file.spec.ts
🔗 Linked issue
📚 Description
this avoids too-eager restarts of nuxt cli