3 ms·
Ive strung up spas within storybook so I have the component and the page its going into. Essentially you import the <App> and provide a store. It helps single r
by scsilver 6y ago
Ive strung up spas within storybook so I have the component and the page its going into. Essentially you import the <App> and provide a store. It helps single responsibility principalize your code, and you are always focused on having well define components for your storybook library/dictionary.
- sbarre 6y agoDo you have any examples you can share where you've customized Storybook in this manner? If I understand correctly, as opposed to loading your components in isolation in Storybook, you're providing them with a context similar to the actual app they're going to exist in?
- artboomy 6y agoNot OP, but i suppose you can use custom decorator to wrap components and globalTypes for some customization, like theme selector https://storybook.js.org/docs/react/essentials/toolbars-and-globals#global-types-and-the-toolbar-annotation https://storybook.js.org/docs/react/essentials/toolbars-and-...
- meagher 6y agoThis sounds like a good use case for Playroom too https://github.com/seek-oss/playroom https://github.com/seek-oss/playroom