Skip to content
This repository has been archived by the owner on Sep 7, 2021. It is now read-only.

TwoStoryRobot/storybook-addon-docgen

Repository files navigation

Build Status npm (scoped)

storybook-addon-docgen

Generates documentation using react-docgen

Development

# Fork this repo and git clone it
npm install
npm run storybook

Usage

Add the addon to your .storybook/addons.js

import '@twostoryrobot/storybook-addon-docgen/register'

Add the docgen decorator to your stories. You must supply the component you want the documentation from. In this case we want to docs supplied from the Button component.

import docgen from '@twostoryrobot/storybook-addon-docgen'

storiesOf('Button', module)
  .addDecorator(docgen(Button))
  .add('with text', () => (
    <Button onClick={action('clicked')}>Hello Button</Button>
  ))

About

Generates documentation using react-docgen

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published