Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A Downshift depedency causes an import error when running in Vite #89

Closed
stdavis opened this issue Jul 1, 2022 · 3 comments
Closed
Labels
bug Something isn't working sherlock all things worth looking for

Comments

@stdavis
Copy link
Member

stdavis commented Jul 1, 2022

Installing a @ugrc/sherlock into a freshly bootstrapped vite app causes the dev build to fail with the following message in the console...

Uncaught SyntaxError: The requested module '/node_modules/prop-types/index.js?v=e115d97d' does not provide an export named 'default' (at index.es.js?v=e115d97d:2:8)

This older issue in the Downshift repo appears to be a similar problem but the suggested fix is a deprecated option in the associated @rollup/plugin-commonjs package. I tried adding this plugin to the project and vite config but it didn't seem to have any effect.

@stdavis stdavis added the sherlock all things worth looking for label Jul 1, 2022
stdavis added a commit to agrc/atlas that referenced this issue Jul 1, 2022
Point prettier at more files.

Blocked by agrc/kitchen-sink#89
@steveoh
Copy link
Member

steveoh commented Jul 5, 2022

Does that mean that downshift should be a peer dependency?

@steveoh steveoh added the bug Something isn't working label Jul 7, 2022
@stdavis
Copy link
Member Author

stdavis commented Jul 11, 2022

Does that mean that downshift should be a peer dependency?

I wouldn't think so since it needs to be installed regardless. But maybe?

@steveoh
Copy link
Member

steveoh commented Jul 21, 2022

this is because the jsx was not compiled and vite doesnt' optimize them. closed by #105

@steveoh steveoh closed this as completed Jul 21, 2022
stdavis added a commit to agrc/atlas that referenced this issue Jul 22, 2022
Point prettier at more files.

Blocked by agrc/kitchen-sink#89
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working sherlock all things worth looking for
Projects
None yet
Development

No branches or pull requests

2 participants