feat: add rsbuild adapter#608
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)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughAdds a first-class Rsbuild adapter to unplugin. This includes new type definitions for the Rsbuild framework, a refactored rspack hook-wiring routine ( ChangesRsbuild First-Class Adapter
Sequence Diagram(s)sequenceDiagram
participant PluginAuthor
participant createRsbuildPlugin
participant getRsbuildPlugin
participant toRsbuildPlugin
participant RsbuildAPI
participant getRspackPluginFromRaw
PluginAuthor->>createRsbuildPlugin: UnpluginFactory
createRsbuildPlugin->>getRsbuildPlugin: factory
getRsbuildPlugin->>getRsbuildPlugin: build meta {framework:'rsbuild'}
getRsbuildPlugin->>toRsbuildPlugin: rawPlugin[]
toRsbuildPlugin-->>PluginAuthor: RsbuildPlugin
PluginAuthor->>RsbuildAPI: register via rsbuild.config
RsbuildAPI->>toRsbuildPlugin: setup(api)
toRsbuildPlugin->>toRsbuildPlugin: meta.versions.rsbuild = api.context.version
toRsbuildPlugin->>getRspackPluginFromRaw: rawPlugin[]
getRspackPluginFromRaw->>RsbuildAPI: RspackPlugin
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ 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 |
Summary
Closes #607
createUnplugin(...).rsbuildandcreateRsbuildPlugin.modifyRspackConfighook.meta.versions.rsbuildand the underlyingmeta.versions.rspack.Tests
pnpm typecheckpnpm test:buildpnpm vitest runpnpm buildSummary by CodeRabbit
New Features
Documentation
Tests
Chores