storybook icon indicating copy to clipboard operation
storybook copied to clipboard

Storybook v7 - Error: Sorry, for now, you can not do this, please use a framework such as @storybook/react-webpack5

Open humarkx opened this issue 2 years ago • 3 comments

When running npx [email protected] init Or any other 7 alpha release I get the following error: Error: Sorry, for now, you can not do this, please use a framework such as @storybook/react-webpack5

A brand new project Vite with react ts template

image

humarkx avatar Jun 29 '22 12:06 humarkx

i don't think vite is supported just yet - it doesn't have a framework. storybook 7 also includes several breaking changes that are not supported by @storybook/builder-vite (as of v0.2.0-beta.2).

esm support received some major updates, so i was hoping to use patch-package to workaround some of the kinks, but after hitting a wall and checking out the wip on the framework-vite branch, i'm thinking we have to submit some PRs haha, or wait for a release.

@shilman or @IanVS can you confirm?

unicornware avatar Jul 11 '22 23:07 unicornware

That's right, although I hear it's coming very soon!

IanVS avatar Jul 12 '22 04:07 IanVS

@humarkx Do you still encounter this? Storybook 7 now has vite support.

joshwooding avatar Sep 21 '22 10:09 joshwooding

works now

npm create vite@latest typescript react

npx [email protected] init work

npx [email protected] init --builder @storybook/builder-vite not work

image

himyjan avatar Oct 07 '22 04:10 himyjan

The flag is --builder=vite, which should work hopefully. We should throw an error on bad values...

IanVS avatar Oct 07 '22 10:10 IanVS

The flag is --builder=vite, which should work hopefully. We should throw an error on bad values...

with the --builder=vite flag it worked for me! Thanks!

eliabyteixeira avatar Apr 24 '23 03:04 eliabyteixeira