Skip to content

Storybook

Julian Müller edited this page Jan 13, 2023 · 1 revision

Storybook (https://storybook.js.org/) is a demoing environment that you can use as a playground for UI components.
We encourage you to write stories for each component you create - it is not hard to learn and very helpful to both you and people who want to make use of the code you wrote.
See here for a primer on how to use Storybook with Web Components: https://storybook.js.org/docs/web-components/get-started/introduction or just check out the stories we wrote for the Scatterplot component (stories/BiowcScatter.stories.ts). Please put your own stories into this folder as well. Same as for testing, please use Fixtures to feed your stories with data.

Troubleshooting

Storybook has problems with Version 18 of Node. To downgrade (e.g. to Version 16) please use the node version manager (nvm) as follows:

curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.3/install.sh | bash
nvm install 16
nvm use 16

Clone this wiki locally