Skip to content
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

outdated storybook configuration with TSDX create #1188

Open
FlynnHillier opened this issue Apr 28, 2024 · 1 comment
Open

outdated storybook configuration with TSDX create #1188

FlynnHillier opened this issue Apr 28, 2024 · 1 comment

Comments

@FlynnHillier
Copy link

Current Behavior

When creating a new bootstrapped project with npx tsdx create my-app TSDX installs the latest versions of @storybook/react (currently 8.0.9) and other @storybook dependencies. However, TSDX seems to configure the project to support an outdated version of storybook (I think version 6.x.x). As a result you are unable to use storybook from a freshly built tsdx project.

The project's storybook scripts also reference deprecated storybook scripts that are not installed by tsdx.

"storybook": "start-storybook -p 6006",
"build-storybook": "build-storybook"

Expected behavior

Be able to run storybook from a fresh project created by tsdx create, without the need for re-configuration.

Suggested solution(s)

With an additional dependency @storybook/cli the storybook scripts should become:

"storybook": "sb dev -p 6006",
"build-storybook": "sb build"

Additional context

Similar to #1179, but re-opening because of storybook V8 release.

It would seem some users have had success running npx storybook@next automigrate in order to migrate the tsdx project to a compatible version of storybook. However, this did not work for me - it is also not really ideal to have to manually patch configuration hence the solution even if it works is not desirable.

Your environment

  System:
    OS: Windows 11 10.0.22631
    CPU: (28) x64 Intel(R) Core(TM) i7-14700K
    Memory: 13.15 GB / 31.78 GB
  Binaries:
    Node: 20.11.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.21 - ~\AppData\Roaming\npm\yarn.CMD
    npm: 10.2.4 - C:\Program Files\nodejs\npm.CMD
  Browsers:
    Edge: Chromium (123.0.2420.97)
    Internet Explorer: 11.0.22621.1
  npmPackages:
    tsdx: ^0.14.1 => 0.14.1 
    typescript: ^5.4.5 => 5.4.5 
@pablim
Copy link

pablim commented Sep 26, 2024

Same problem!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants