-
Notifications
You must be signed in to change notification settings - Fork 24
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
[Bug]: Storybook imports extra unnecessary files #72
Comments
Do you get this error during development or only when running a build? |
In both sadly :( |
@ChrisEdson if you update react-native-progress to "react-native-progress": "^5.0.1" it actually solves the web compatibility issues. Though I do see how its unforunate that unused files are transpiled, I'm not sure right now why that is. I will have to check that. |
Thanks for looking in to this! You're absolutely right and it does - this was just a random library I chose, but plenty of others have the same problem that exist in my main repo - I.e. they get included and attempted to be bundled. Appreciate you taking a look :) |
closing as duplicate of #77 |
Describe the bug
Storybook imports random files when used with
@storybook/addon-react-native-web
.This causes the build to fail.
An example repository can be found here and the failing build here.
You can see the error is:
This is a typical transpilation error that you see with
react-native-web
- but the<ImageProgress />
component is not being imported in to any of the stories (of which there is only one: https://github.com/ChrisEdson/storybook-test/blob/main/src/components/ui/DesignSystemHeadlineFive.stories.tsx).I'm really confused by this. The
stories
property inmain.js
only specifies stories to be included:stories: ["../src/**/*.stories.@(js|jsx|ts|tsx)"],
To Reproduce
https://github.com/ChrisEdson/storybook-test
System
The text was updated successfully, but these errors were encountered: