Felix Kling
Felix Kling
`react-docgen` only looks at files in isolation. It doesn't know that `Button` inside `hello-button.js` is a React component. What would you expect the result for `hello-button.js` to be? It shouldn't...
@threehams: Yeah, I just recently thought about that too. Do you have something concrete in mind?
@FezVrasta: Maybe https://github.com/Jmeyering/react-docgen-annotation-resolver helps you. The general problem is that there is no standard format for HOCs. A possible solution is to write custom resolvers and handlers for specific types...
@FezVrasta: The resolver I linked to allows you to do that.
I guess we could special case `Object.assign`, but a quick solution would be to use: ```js ParentComponent.propTypes = { ...ChildComponent.propTypes, parentPropA: React.PropTypes.string, }; ``` which react-docgen understands (and which is...
@bsmith-cycorp: Sorry for not have followed up on this! You are right, `static get propTypes()` doesn't work but it definitely should. Feel free to open a new issue about this.
I guess we could do this for simple cases, where a variable is spread into `propTypes` (i.e. `...foo`, but not `..foo.bar`) and that variable resolves to a module import. I...
@asis: They are not ignored: https://github.com/reactjs/react-docgen/blob/00f2d2d62d93b9243157c4cea19cf241121a7721/src/handlers/__tests__/propTypeCompositionHandler-test.js, but they are stored separately from normal props.
@RIP21 The recommended approach (which is also what we do at Facebook), is to merge the docs yourself. I.e. since you know that this component composes `semantic-ui-react`, you can look...
@RIP21: Have you tried using @pasupuletics' custom handler? > Can somebody integrate such finally :( Supporting dependency resolution in such a way that it works reliably in various environments is...