yassilah / nuxt-storybook

10 stars 0 forks source link

error Command "start-storybook" not found. #2

Open Draichi opened 1 year ago

Draichi commented 1 year ago

Hello,

First of all thanks for your effort

But I could not get this running in my nuxt 3 project, I followed the 2 steps on the readme but got stuck on what to do next, so I created a "storybook" script in my package.json calling "start-storybook" but this command was not found. So I installed @storybook/vue3 to solve this problem but now my issue is:

ERR! TypeError: Cannot read properties of undefined (reading 'NormalModule')
ERR!     at VueLoaderPlugin.apply (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/vue3/node_modules/vue-loader/dist/pluginWebpack5.js:44:47)
ERR!     at webpack (/Users/diegomaradona/Code/draichiboard/node_modules/webpack/lib/webpack.js:51:13)
ERR!     at starterGeneratorFn (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/builder-webpack4/dist/cjs/index.js:137:18)
ERR!     at starterGeneratorFn.next (<anonymous>)
ERR!     at Object.start (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/builder-webpack4/dist/cjs/index.js:275:34)
ERR!     at async Promise.all (index 0)
ERR!     at async storybookDevServer (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/vue3/node_modules/@storybook/core-server/dist/cjs/dev-server.js:203:28)
ERR!     at async buildDevStandalone (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/vue3/node_modules/@storybook/core-server/dist/cjs/build-dev.js:120:31)
ERR!     at async buildDev (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/vue3/node_modules/@storybook/core-server/dist/cjs/build-dev.js:174:5)
ERR!  TypeError: Cannot read properties of undefined (reading 'NormalModule')
ERR!     at VueLoaderPlugin.apply (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/vue3/node_modules/vue-loader/dist/pluginWebpack5.js:44:47)
ERR!     at webpack (/Users/diegomaradona/Code/draichiboard/node_modules/webpack/lib/webpack.js:51:13)
ERR!     at starterGeneratorFn (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/builder-webpack4/dist/cjs/index.js:137:18)
ERR!     at starterGeneratorFn.next (<anonymous>)
ERR!     at Object.start (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/builder-webpack4/dist/cjs/index.js:275:34)
ERR!     at async Promise.all (index 0)
ERR!     at async storybookDevServer (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/vue3/node_modules/@storybook/core-server/dist/cjs/dev-server.js:203:28)
ERR!     at async buildDevStandalone (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/vue3/node_modules/@storybook/core-server/dist/cjs/build-dev.js:120:31)
ERR!     at async buildDev (/Users/diegomaradona/Code/draichiboard/node_modules/@storybook/vue3/node_modules/@storybook/core-server/dist/cjs/build-dev.js:174:5)

I'm opening this issue mainly to give you a feedback on how your module is working

thanks

scscgit commented 1 year ago

I also wasn't able to find any command to get this module working. All alternative solutions also lack any valid documentation, so I'm unable to run storybook in Nuxt 3 at all, even using any recommended workarounds.

+ Note that there is no information regarding if this is supposed to be compatible with Storybook version 6 or 7.

Draichi commented 1 year ago

If this helps anyone in any way: I'm moving to Vue Histoire. Storybook was built for React, there are a lot of complications to run it, it should be easy. Let's see if with Histoire is better