Replies: 1 comment
-
If the thing you want to fetch is just the theme values/tokens, then you could try defining your theme contract upfront (at build time), and then dynamically assigning values/tokens that you've fetched at runtime using the |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I am working on a project (remix 2.8.1 and vanilla-extract/css 1.14.2 ): https://github.com/jwpaine/base
I'd like to query theme data from a GraphQL server, and pass the theme data (key-value pairs) to createTheme. I'm running into two issues. The first and biggest roadblock is:
dynamicTheme.ts is responsible for fetching and creating the theme:
styles.css.ts houses theme contract and styles:
...and root.tsx loads the dynamically generated theme:
I'm hoping someone might point me in the right direction? Is dynamic theming like this possible with vanilla-extract?
Thank you!
John
Beta Was this translation helpful? Give feedback.
All reactions