react-showroom-client icon indicating copy to clipboard operation
react-showroom-client copied to clipboard

Add an ability to generate "Props Reference" section based on PropTypes definition in component

Open mpritchin-sc opened this issue 7 years ago • 1 comments

The main idea it's use propTypes definition of components for generationg "Props Reference" section in documentation.

Example: PropTypes definition of component:

...
static propTypes = {
   /** Source value */
    value: PropTypes.string
};
...

Generated PropTypes section in documentation:

| Name               | Type            | Description                                     | Is required | 
| -----------------|------------- |-------------------------------------- |-------------|
| value                | string          |  Source value                                  |   false         |
| -----------------|------------- |-------------------------------------- |-------------|

mpritchin-sc avatar Jan 29 '18 09:01 mpritchin-sc

Thanks, @mpritchin-sc. We'll consider your suggestion.

kvolkovich-sc avatar Jan 29 '18 09:01 kvolkovich-sc