You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems that the change to add the on-demand store has broken the vite builder with react. The build completes, but I see two runtime errors, one for MDX and the other for component stories.
In MDX stories:
Uncaught TypeError: storyById is not a function
at DocsContainer (DocsContainer.js:40)
at renderWithHooks (react-dom.development.js:14985)
at mountIndeterminateComponent (react-dom.development.js:17811)
at beginWork (react-dom.development.js:19049)
at HTMLUnknownElement.callCallback2 (react-dom.development.js:3945)
at Object.invokeGuardedCallbackDev (react-dom.development.js:3994)
at invokeGuardedCallback (react-dom.development.js:4056)
at beginWork$1 (react-dom.development.js:23964)
at performUnitOfWork (react-dom.development.js:22776)
at workLoopSync (react-dom.development.js:22707)
And in normal react stories:
Error: Target container is not a DOM element.
at Object.render (react-dom.development.js:26091)
at render.js:62
at new Promise (<anonymous>)
at _callee$ (render.js:61)
at tryCatch (runtime.js:63)
at Generator.invoke [as _invoke] (runtime.js:294)
at Generator.next (runtime.js:119)
at asyncGeneratorStep (render.js:36)
at _next (render.js:38)
at render.js:38
I traced down the second one a little bit, and it is happening in app/react/src/client/preview/render.tsx in renderElement. My guess is that it's being called when it shouldn't be, but I don't know why.
To Reproduce:
cd packages/example-react in this repo, then run npx sb@next upgrade --prerelease and yarn storybook.
Note, this is without enabling feautres.storyStoreV7.
The text was updated successfully, but these errors were encountered:
Ok, the issue here is something in the yarn setup. There were still 6.3.3 versions of certain packages running in the bundle. When I ran the upgrade command in the other two example apps, all packages seemed to be at 6.4.0-beta.0 and the SB seemed to operate normally.
ooooo, good catch! We've struggled with the mono-repo hoisting / not hoisting mess before. Maybe it's indeed time to try out pnpm (there's even an open PR to do just that). Thanks for the help!
IanVS
changed the title
Storybook-builder-vite breaks with storybook 6.4.0-alpha.35 and higher
react-example fails to upgrade to storybook 6.4.0
Oct 11, 2021
It seems that the change to add the on-demand store has broken the vite builder with react. The build completes, but I see two runtime errors, one for MDX and the other for component stories.
In MDX stories:
And in normal react stories:
I traced down the second one a little bit, and it is happening in
app/react/src/client/preview/render.tsx
inrenderElement
. My guess is that it's being called when it shouldn't be, but I don't know why.To Reproduce:
cd packages/example-react
in this repo, then runnpx sb@next upgrade --prerelease
andyarn storybook
.Note, this is without enabling
feautres.storyStoreV7
.The text was updated successfully, but these errors were encountered: