-
Notifications
You must be signed in to change notification settings - Fork 613
feat(mitosis): code gen support for named slots #1334
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
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
☁️ Nx Cloud ReportCI is running/has finished running commands for commit f269461. As they complete they will appear below. Click to see the status, the terminal output, and the build insights. 📂 See all runs for this CI Pipeline Execution ✅ Successfully ran 4 targetsSent with 💌 from NxCloud. |
@@ -15,4 +15,5 @@ export interface ToReactOptions extends BaseTranspilerOptions { | |||
*/ | |||
contextType?: 'context' | 'prop-drill'; | |||
addUseClientDirectiveIfNeeded?: boolean; | |||
noPrefixSlots?: boolean; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given #1301, I think we want the default to be not prefixing.
Would you mind switching this to:
noPrefixSlots?: boolean; | |
prefixSlots?: boolean; |
and only prefixing if the option was explicitly provided?
This will require updating the snapshot tests, which you can do by running:
yarn ci:build
in the root, and thenyarn snapupdate
inpackage/core
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Scratch that: if you don't mind, completely remove the prefixing logic altogether! We don't need it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
@samijaber updated tests and readme to reflect new slot behavior |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice 👍🏽
Description
This PR adds support for named slots in custom component code gen: https://www.loom.com/share/f3ad5eee72f9486a9130ce1f09ceafa0
Fixes #1301