Open Demiurg77 opened 1 year ago
I'm a little surprised about this -- I would expect it to work. Do you a have a reproduction repo you can share? If not, can you create one? Go to https://storybook.new or see repro docs. I'd be happy to take a look.
@shilman I added reproduction repo and storybook preview to "To Reproduce" section
Thanks so much! I'll take a look
Hi @shilman. Any updates on this? Code preview is the only feature that stops us from migrating to v7. Also could you remove "needs reproduction" tag from this thread?
BTW, one more aspect regarding source preview, connected with this issue: https://github.com/storybookjs/storybook/discussions/23135
@Demiurg77 I was out last week but will try to get to the bottom of it this week. Thanks for your patience!
@Demiurg77 Side note -- I don't understand why this is blocking you from upgrading to v7, given that according to you this doesn't work in v5/v6 either.
@Demiurg77 Side note -- I don't understand why this is blocking you from upgrading to v7, given that according to you this doesn't work in v5/v6 either.
@shilman I guess I didn't make myself clear, but both methods work fine in previous versions. The problem is only with Storybook 7.
In storybook 6.5 I can successfully use export * from "./avatar.basic.story"
or export { Basic } from "./avatar.basic.story"
, and source preview works as expected
@Demiurg77 Gotcha, thanks for clarifying!
Describe the bug
In Storybook 7 while re-exporting stories via:
I can see a story, but I can't preview the source ("Show code / Hide code" button is disabled)
BTW - using old way with asterisk (Storybook 5, 6) in Storybook 7 doesn't show the story, neither the source code:
Some stories are quite large and I need to keep them in separate tsx files.
To Reproduce
Storybook preview: https://64978ad79679888cd8f5f436-fzgpjawimm.chromatic.com/?path=/docs/example-button--docs
Repository: https://github.com/Demiurg77/my-storybook-reproduction/tree/main/src/stories
Reproduction build details: https://www.chromatic.com/build?appId=64978ad79679888cd8f5f436&number=2
System
Additional context
No response