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 build not working due to error from plugin-transform-block-scoping
: Cannot set properties of undefined (setting 'kind')
#20382
Comments
Same problem here, when trying to integrate with next.js |
Same problem here, working on an independent package, using |
Same problem here, I don't believe this is related to CRA, but rather likely something either which is unlocked or upgraded in SB Note that we are not using CRA and still running into this issue. |
Note I've found that we can add the following to the
v7.20.5 is the latest version which appears to work properly. |
Same here, even pure storybook for react install doesn't work either 😕.
then
Anyone cannot start with current stable - 6.5.15 - storybook for react component. It makes very bad reputation on newcomers. Even if problem is with 3rd party libs, it's still very bad for project as storybook. No daily QA builds failed? |
I also ran into this issue, and with a clean copy of create-react-app (TypeScript) and storybook (7.0), I could replicate the issue by removing the I'm not sure why this is required, as it wasn't before, and I can't find any information about it in the storybook docs. "browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
}, |
@neogeek I'm guessing it's because Babel packages integrate with the Weirdly enough my error changes after adding
|
Looks like they are already working on a solve #20383 |
Yes, I am, but I'm dependent on the babel team here... I'm afraid.. |
@neogeek thank you for that information, anything might help. Hopefully it can be quickly resolved by the babel team. |
Thank you for posting your work-around @cjones26 👏 I wish I could upvote it twice |
Looks like another issue is created on their repo here: babel/babel#15302 |
plugin-transform-block-scoping
: Cannot set properties of undefined (setting 'kind')
Unfortunately, the workaround proposed by @cjones26 isn't working here. Is there anything else that could be tried? |
Using |
@emiliosheinz I know it's a silly question but have you done an |
@emiliosheinz Yep, if you're using yarn you need to use |
@cjones26 I didn't know it, my bad! Thank you for the help. |
There was an updated version of https://www.npmjs.com/package/@babel/plugin-transform-block-scoping pushed. After removing the |
confirmed that babel fix the plugin (thx @neogeek for info) so
I didn't test other workaround (resultions, overrides ...), but when new storybook patch will be published, you can remove workarounds and update into latest patch. I think it can be closed, thank you guys for your work on it. |
Yay!! I just released https://github.com/storybookjs/storybook/releases/tag/v7.0.0-beta.14 containing PR #20386 that references this issue. Upgrade today to the
Closing this issue. Please re-open if you think there's still more to do. |
Describe the bug
After initiating a fresh React app, and then initiating storybook and running
yarn build-storybook
I get a build error:I can reproduce this on 2 different computers.
To Reproduce
System
Additional context
No response
The text was updated successfully, but these errors were encountered: