Substories/Hierarchy
See original GitHub issueWould be nice to be able to have “Substories” or a Hierarchy of stories. My case involves various mini “apps” being contained in the same repo. A simple solution would be an option to display stores named like ui.core.foo
and ui.core.bar
like:
ui
└── core
├── bar
└── foo
With support for expanding and collapsing nodes.
Issue Analytics
- State:
- Created 7 years ago
- Reactions:113
- Comments:80 (32 by maintainers)
Top Results From Across the Web
Naming components and hierarchy - Storybook - JS.ORG
We recommend naming components according to the file hierarchy. Single story hoisting. Stories which have no siblings (i.e. the component has only one...
Read more >Story Hierarchy in Storybook 3.2. My first open source ...
It's an IDE for the React components. The Holy Grail of the dev — design communication ! It's a beam of light in...
Read more >How can I create a hierarchy of EPIC , Feature, St...
The issuetypes come in three hierarchical flavors: Epic; Story, Task; sub-task. you can create new issue types that equate to level 2 or...
Read more >Sub-story detection in Twitter with hierarchical Dirichlet ...
This paper proposes hierarchical Dirichlet processes (HDP), a probabilistic topic model, as an effective method for automatic sub-story detection. HDP can learn ...
Read more >storybook/addon-chapters - npm package
Adds Substories/Hierarchy to React Storybook For more information about how to use this package see README · Security · Popularity · Maintenance ·...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Currently, we’ve no plan to implement that. That’s because it makes navigation harder. You can namespace story kinds with dot like “ui.core”, “ui.app”. Then you can filter them as you need.
If there are a lot of stories, you can start a few storybook instances. You can do that by having two storybook config directories. But, anyway that’s an extreme case.
Hey, Guys!
Despite the fact that such a feature isn’t planned in the near future this doesn’t mean that we can’t get such behavior via Storybook Addons API
Here is a such addon:
Storybook Chapters
Storybook Chapters
Adds unlimited levels of nesting for (sub)stories
To add one more nesting level just put
.chapter(name)
to your stories:Features
Knobs
,addWithInfo
and other addonsstoryDecorator
to wrap all chaptersDemo page
Project
Example
Any feedback will be very appreciated! 😃