How to pass props to Prose components? #2207
-
Beta Was this translation helpful? Give feedback.
Answered by
nobkd
Jul 31, 2023
Replies: 1 comment 1 reply
-
I don't completely understand, what you want, but I think you're looking for the (A live reproduction with for example Stackblitz would have been helpful) In your excerpt / text component, you might need the content slot, maybe like this: <ContentSlot :use="$slots.default" unwrap="p" /> And, if your Text component is globally available (e.g., in the ::text{variant="huge"}
your text
:: |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
goodpixels
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I don't completely understand, what you want, but I think you're looking for the
<ContentSlot>
component(A live reproduction with for example Stackblitz would have been helpful)
In your excerpt / text component, you might need the content slot, maybe like this:
And, if your Text component is globally available (e.g., in the
components/content
directory), you could use the MDC syntax to use it directly in Markdown and set the props: