Exporting theme helper functions from a library #1527
Unanswered
nick-vincent
asked this question in
Q&A
Replies: 1 comment
-
I've been doing some more investigation on this today... I tried just exporting the theme contract from the lib and then using VE's Again, this works when importing the contract via relative paths, but when importing from the built
Since this seems to be the blessed way to do what I'm trying to do, I'm curious if anyone else has run into this? |
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
-
Hello there!
I'm working on using Vanilla Extract in a design system library and running into an interesting issue...
I have a minimal reproduction repo here to illustrate the situation.
Basically, I'm trying to create and export a
createButtonTheme
helper from the design system package here.I find that if I import the helper via relative paths here the import works and the
greenThemeClass
is successfully created.However, when i build the lib and try to import it from the
/dist/
folder here, the build breaks with this error:I'm guessing something is probably wrong in my build somewhere but I can't seem to figure out what i'm missing 😩
Edit: I should add that the error above is surfaced in the browser but in the terminal logs I see this error:
Beta Was this translation helpful? Give feedback.
All reactions