You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(client): load virtual files from /_vfs/ for Nitro v3 compatibility - #1132
The Virtual Files tab stayed empty on Nuxt 5. Nitro v3 only serves /_vfs/** and no longer answers /_vfs.json. Nitro v2 only handled /_vfs.json because h3 v1 prefix-matches /_vfs. Both versions return JSON for /_vfs/ when the request has Accept: application/json. The client now requests that URL, so the tab works on Nitro v2 and v3.
Note: Nitro still lists entries[].path as /_vfs.json/<id>. The client does not use that field.
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.
📝 Walkthrough
The virtual-file list request now uses /_vfs/ and sends an Accept: application/json header. Requests for individual virtual files now use /_vfs/<fileId> instead of /_vfs.json/<fileId>. JSON response handling remains in place.
The change addresses virtual-file loading compatibility without a remaining actionable merge risk.
Pre-merge checks: 4 · 1
Failed checks: 1 warning
Check name
Status
Explanation
Resolution
Docstring Coverage
Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 1 files. (1 skipped: 1 …
Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed checks: 4 passed
Check name
Status
Explanation
Title check
The title clearly and concisely identifies the client change and its Nitro v3 compatibility purpose.
Description check
The description directly explains the Nitro v2 and v3 endpoint behavior, the client changes, and the issue being fixed.
Linked Issues check
Issue [#1127] requires the client to load virtual files from an endpoint supported by Nitro 3. useVirtualFiles now requests /_vfs/ with Accept: application/json, which matches the issue requirem…
Out of Scope Changes check
The diff changes only the virtual-file list and detail client URLs and the list request header. These changes directly support issue [#1127]. No unrelated source, API, or repository changes are presen…
Full details: Linked Issues check
Explanation
Issue [#1127] requires the client to load virtual files from an endpoint supported by Nitro 3. useVirtualFiles now requests /_vfs/ with Accept: application/json, which matches the issue requirement and preserves JSON parsing. The virtual-file detail request also changed from /_vfs.json/<id> to /_vfs/<id> with the JSON Accept header. No linked issue requires a Nitro route change.
Full details: Out of Scope Changes check
Explanation
The diff changes only the virtual-file list and detail client URLs and the list request header. These changes directly support issue [#1127]. No unrelated source, API, or repository changes are present in the reviewed diff.
Full details: Docstring Coverage
Explanation
Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 1 files. (1 skipped: 1 unsupported.)
Resolution
Write docstrings for the functions missing them to satisfy the coverage threshold.
✨ Finishing Touches: 💡 1
📝 Generate docstrings: 💡
Commit to this branch
Create a new PR
🧪 Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
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.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1127
The Virtual Files tab stayed empty on Nuxt 5. Nitro v3 only serves
/_vfs/**and no longer answers/_vfs.json. Nitro v2 only handled/_vfs.jsonbecause h3 v1 prefix-matches/_vfs. Both versions return JSON for/_vfs/when the request hasAccept: application/json. The client now requests that URL, so the tab works on Nitro v2 and v3.Note: Nitro still lists
entries[].pathas/_vfs.json/<id>. The client does not use that field.This PR was created with the help of an AI agent.