Importing of sub packages with custom main entry (not index.js) #3786
Unanswered
Bunkerbewohner
asked this question in
Troubleshooting
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi!
I'm trying to get snowpack to run with a big existing project which currently uses webpack. Many sub components are organized in separate packages, e.g. like this:
And the
package.json
looks somewhat like this:Other modules import these like this:
With snowpack these imports are rewritten as
/components/Column/index.js
and therefore all produce 404 errors. Instead these should be resolved as/components/Column/Column.js
. As far as I can see there's no configuration to fix this. Any hints on how to get this to work?Beta Was this translation helpful? Give feedback.
All reactions