You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
I have a set of stories, that are developed individually. At the same time, I want to have multiple Storybook configurations, lets say one for internal and one for external docs for simplicity.
Internal documentation should contain all stories with examples, the whole set.
External documentation should however contain only mdx files - Contains componet purpose, basic usage showcase imported from some .stories.tsx files and props. Standalone stories should not be visible in this case, but should still be loaded as some are part of .mdx file (In form of <Canvas of={Stories.variants} />).
If this would be possible, I could easily generate multiple Storybook documentations for different subset of components, based on purpose or client from single codebase.
Describe the solution you'd like
For this use-case, I'd imagine additional attribute in StorybookConfig in main.ts file.
Complete set of stories should be defined as it is now, via stories attribute, and custom set of omited stories could be defined via new omittedStoriesFromNavigation attribute with same value definition (StoriesEntry[]).
Or if there is another way how to achieve this, I'd be happy to hear it.
Describe alternatives you've considered
I have considered this idea about stories hiding, however this solution is not usable in our case, as the story will be hidden in all configurations that load this story.
Definition of omited stories on root configuration level gives higher flexibility I think.
Are you able to assist to bring the feature to reality?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Is your feature request related to a problem? Please describe.
I have a set of stories, that are developed individually. At the same time, I want to have multiple Storybook configurations, lets say one for internal and one for external docs for simplicity.
Internal documentation should contain all stories with examples, the whole set.
External documentation should however contain only mdx files - Contains componet purpose, basic usage showcase imported from some .stories.tsx files and props. Standalone stories should not be visible in this case, but should still be loaded as some are part of .mdx file (In form of
<Canvas of={Stories.variants} />
).If this would be possible, I could easily generate multiple Storybook documentations for different subset of components, based on purpose or client from single codebase.
Describe the solution you'd like
For this use-case, I'd imagine additional attribute in
StorybookConfig
inmain.ts
file.Complete set of stories should be defined as it is now, via
stories
attribute, and custom set of omited stories could be defined via newomittedStoriesFromNavigation
attribute with same value definition (StoriesEntry[]
).Or if there is another way how to achieve this, I'd be happy to hear it.
Describe alternatives you've considered
I have considered this idea about stories hiding, however this solution is not usable in our case, as the story will be hidden in all configurations that load this story.
Definition of omited stories on root configuration level gives higher flexibility I think.
Are you able to assist to bring the feature to reality?
yes, I can
Additional context
No response
Beta Was this translation helpful? Give feedback.
All reactions