Skip to content

Imported propTypes of dependencies #87

@fab1an

Description

@fab1an

I often nest my proptypes like this:

class Parent extends React.Component {
    static propTypes = {
        something: pt.string.isRequired,
        child: pt.shape(Child.propTypes).isRequired
    }
}

react-docgen gives me

"type": {
    "name": "shape",
    "value": "unkown"
},

for the parameter. Can I somehow make it give me Child? I tried using instanceOf() but that didn't work either.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions