fix(devtools-vite): preserve valid syntax when removing devtools JSX#480
fix(devtools-vite): preserve valid syntax when removing devtools JSX#480vedant416 wants to merge 2 commits into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughThe removeDevtools transform's replacement logic is changed: devtools nodes nested inside JSXElement or JSXFragment are now fully removed, while nodes in other expression contexts are replaced with null instead of removed outright. Tests are updated/extended accordingly, and a changeset documents the fix. ChangesDevtools removal syntax fix
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 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 |
🎯 Changes
Fixes #457
Issue Summary
<TanStackDevtools />) was beingfully removedwithout taking into account the context in which it was being used.Fix
fully removedwhen their parent is aJSXElementorJSXFragment.nullinstead, which is always valid as an expression.✅ Checklist
pnpm test:pr.🚀 Release Impact
Summary by CodeRabbit