Replies: 2 comments
-
hi @sajcics I don't exactly understand what you really try to achieve. If I understand correctly, you want to have a the same as if you had a single file that looks like this below, but want to split those "FirstStory" "SecondStory" into single files?
|
Beta Was this translation helpful? Give feedback.
0 replies
-
are you looking for this? https://www.npmjs.com/package/@storybook/addon-storysource |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Describe the bug
Storybook addon is not showing right code snippet of the story. When I have multiple stories for one component, and export stories in one file, storybook is not recognizing when should show correct code snippets.
For example I have a file
Component1.stories.js
:and inside storybook if I go to
First
story orSecond
story it will show code fromComponent1.stories.js
event it should recognize when I'm in specific story. Btw,First.stories.js
andSecond.stories.js
are not export any default values such asComponent1.stories.js
, which means that I am exporting those file correctly inside ofComponent1.stories.js
.To Reproduce
Steps to reproduce the behavior:
Expected behavior
Storybook addon for code snippets should recognize correct file which should show code.
If I have file structure in storybook like this:
System
Beta Was this translation helpful? Give feedback.
All reactions