Replies: 4 comments
-
In the end I've taken the approach of adding class names on all markdown rendered elements (via https://github.com/martypdx/rehype-add-classes) and this appears to work pretty well. It would still be good to know how I can use sprinkles with |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
-
Any other suggestions then? |
Beta Was this translation helpful? Give feedback.
-
I've created some utils for myself to have Tailwind CSS Typography working with vanilla-extract: https://github.com/LekoArts/portfolio-v2/blob/main/www/src/utils/vanilla-extract.ts Until I write about that you can check the unit tests. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
For rendering markdown content I need to use descendant selectors to style markup tags. (Similar to https://github.com/tailwindlabs/tailwindcss-typography)
So let's say I have a link component with corresponding styles:
Now for my markdown content I want to use exactly the same styles for styling
a
tags.Ideally I'd like to do:
...but that obviously doesn't work because
globalStyle
expects a style object and not aclassName
string.I'm still getting familiar with the API but I don't really understand how I can re-use styles using
globalStyle
. Is there a different approach I can take here to share styles using descendant selectors?Beta Was this translation helpful? Give feedback.
All reactions