-
Notifications
You must be signed in to change notification settings - Fork 1.3k
feat: 🎸 Add support for custom TypeScript transformers #3732
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
WalkthroughThe changes add support for passing custom TypeScript transformers through the Vendure dashboard Vite plugin and its underlying compiler utility. New optional Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant VitePlugin
participant Compiler
User->>VitePlugin: vendureDashboardPlugin({ customTransformers })
VitePlugin->>Compiler: compile({ ..., customTransformers })
Compiler->>Compiler: Merge customTransformers with defaults
Compiler->>Compiler: compileTypeScript(..., mergedCustomTransformers)
Compiler->>VitePlugin: Compilation result
VitePlugin->>User: Plugin setup complete
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Assessment against linked issues
Assessment against linked issues: Out-of-scope changes
Note ⚡️ Unit Test Generation is now available in beta!Learn more here, or try it out under "Finishing Touches" below. 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (2)
🧰 Additional context used🧠 Learnings (4)📚 Learning: applies to packages/dashboard/src/lib/components/**/*.{tsx,jsx} : use shadcn ui and tailwind css for...Applied to files:
📚 Learning: applies to packages/dashboard/src/**/*.{tsx,jsx} : use react for all ui components in the dashboard ...Applied to files:
📚 Learning: applies to packages/dashboard/src/app/routes/**/*.tsx : use tanstack router for all routing and navi...Applied to files:
📚 Learning: applies to packages/dashboard/src/**/*.{ts,tsx} : use tanstack query (usequery or usemutation) for d...Applied to files:
🧬 Code Graph Analysis (1)packages/dashboard/vite/utils/compiler.ts (2)
🔇 Additional comments (9)
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
|
|
👋 Hi team, I noticed that PR #3732 introduces support for custom TypeScript transformers, which is a great feature — thanks for the effort! However, as the original issue #3727 specifically refers to supporting import.meta.url and ESM in the dashboard compilation, it seems this PR may not directly address that need. If the team agrees, I’d be happy to explore a dedicated solution to enable proper handling of import.meta.url in the Vite-based dashboard build, possibly using a transformer or alternative approach. Let me know if that would be helpful — I’d love to contribute further. 🙌 Best regards, |
|
It is very necessary to support import.meta |



✅ Closes: #3727
feat: Add support for custom TypeScript transformers in Vendure dashboard plugin
This update introduces a new option for custom TypeScript transformers in the Vite plugin, allowing users to customize the TypeScript compilation process. The changes include updates to the
CompilerOptionsinterface and the compilation logic to merge user-defined transformers with default ones.Summary by CodeRabbit