Replies: 1 comment 1 reply
-
Hi @cherihung sorry that's happening, do you have this code on Github so I could try to replicate it? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi, we are running into a similar issue still using the latest snowpack 2.13.3 with the namedExports support. It's a typescript project. could be an issue with unwrapping exports and mixing of import types. not sure if there's rollup config I can use to address this.
I'm importing a custom styled component library so I declared the exports with something like this:
in the app itself, I import the custom styled component:
When I start up the dev build, I get a
Uncaught TypeError: styled_components_1.default.svg is not a function
error.because in runtime with snowpack, the actual default is in
styled_components_1.default.default.svg
I suspect the error is likely from the unpacking.
The source, compiled file:
The runtime file in browser:
any advice on how best to handle this? a custom rollup that I can pass into snowpack.config?
Originally posted by @cherihung in https://github.com/pikapkg/snowpack/issue_comments/708147667
Beta Was this translation helpful? Give feedback.
All reactions