1

Whatever I'm doing I'm not able to generate docs for components that uses JSDoc.

For e.g.

The following code:

/**
 * @param {{name:string}} props
 * */
export function Button(props) {

}

Should show me:

enter image description here

To see the props I must use propTypes

Button.propTypes = {
  name: PropTypes.string,
}

So, how to make react-styleguidist to work with JSdoc (or even kind of typescript).

A working example would be appreciate.

Aminadav Glickshtein
  • 23,232
  • 12
  • 77
  • 117

1 Answers1

1

You can only use @param when documenting props.

Here you can find more about how to use JSDoc tags: https://react-styleguidist.js.org/docs/documenting.html#using-jsdoc-tags