Storybook: Does not work with @nuxtjs/compositon-api v0.24

Created on 29 May 2021  Â·  1Comment  Â·  Source: nuxt-community/storybook

Version

@nuxtjs/storybook: v4.0.2
nuxt: 2.15.6

Reproduction Link

https://github.com/norioxkimura/nuxt-storybook-bug-20210529

Steps to reproduce

$ git clone https://github.com/norioxkimura/nuxt-storybook-bug-20210529
$ cd nuxt-storybook-bug-20210529
$ cd 0.24-ng
$ npm ci
$ npm run storybook
  • The <counter> component implemented using composition-api doesn't work.

スクリーンショット 2021-05-29 17 48 23

What is Expected?

  • It worked before 0.24 of @nuxtjs/composition-api.
$ cd ../0.23-ok
$ npm ci
$ npm run storybook

スクリーンショット 2021-05-29 17 43 08

  • Only difference is the version of @nuxtjs/composition-api

What is actually happening?

  • I think the cause of the bug is the commit of @nuxtjs/composition-api.
  • The release note of 0.24.0 says: (outside of Nuxt) only auto-registers plugin if NODE_ENV == 'test'
  • By temporarily change node_modules/@nuxtjs/storybook/dist/cli.js as process.env.NODE_ENV = 'test'; (See code), my story of <counter> works well again.
bug

Most helpful comment

@norioxkimura Thanks for the report! This should be fixed in v0.24.3 of @nuxtjs/composition-api.

>All comments

@norioxkimura Thanks for the report! This should be fixed in v0.24.3 of @nuxtjs/composition-api.

Was this page helpful?
0 / 5 - 0 ratings