-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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]: Babel warning when using a function for base configuration for angular #20940
Comments
Hey @Tallyb thank you so much for reporting this issue! Did this happen when you migrated from Storybook 6? In Storybook 7 we rely a lot on AST parsing of your Storybook-related files, which has some caveats, such as not being able to evaluate the Still, I'm quite curious which was the previous version you were using that this was working, so please let me know if you can. Thanks! |
hi @yannbf! We are running multiple angular storybooks that have a large common configuration, just with a minor change, hence the function. As it is a warning on ts file, I guess we will live with it. Of course, a fix would be awesome... |
Thanks for explaining, it definitely is related to that PR! I'm reverting that change and turning that check into an automigration instead! Having "unconventional" main.js files like yours is fine, however with the caveat that some of our automigrations won't be able to migrate your code on your behalf, FYI. Regardless, the upcoming alpha will be working fine for your scenario! |
Ooh-la-la!! I just released https://github.com/storybookjs/storybook/releases/tag/v7.0.0-beta.44 containing PR #20952 that references this issue. Upgrade today to the
|
Describe the bug
Unexpected {"type":"ExportDefaultDeclaration", ...long warning
This happens when you have a file (ts or mjs) that exports a function that is later used as base configuration.
To Reproduce
https://github.com/Tallyb/taskbox run `npx ng run taskbox:storybook`
System
Additional context
No response
The text was updated successfully, but these errors were encountered: