Skip to content

Commit

Permalink
Document how to add idividual story description, see storybookjs#8527 s…
Browse files Browse the repository at this point in the history
  • Loading branch information
David Hill committed Jun 29, 2021
1 parent cbbef5b commit 28cf4ee
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions addons/docs/docs/recipes.md
Expand Up @@ -336,6 +336,22 @@ import { theme } from '../path/to/theme'
Rest of your file...
```

## Add doc to individual stories

Add `storyDescription` to `parameters.docs`

```js
const Example = () => <Button />;

Example.parameters = {
docs: {
storyDescription: "Individiual story description, may conatin `markdown` markup",
},
};
```

There is also an webpack loader package that extracts descriptions from jsdoc comments [story-description-loader](https://www.npmjs.com/package/story-description-loader)

## More resources

- References: [README](../README.md) / [DocsPage](docspage.md) / [MDX](mdx.md) / [FAQ](faq.md) / [Recipes](recipes.md) / [Theming](theming.md) / [Props](props-tables.md)
Expand Down

0 comments on commit 28cf4ee

Please sign in to comment.