Skip to content

Commit

Permalink
feat: Render union types prop info
Browse files Browse the repository at this point in the history
  • Loading branch information
jerelmiller committed Jun 7, 2020
1 parent f973f9f commit bc5e17a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/components/PropTypeInfo.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ const PropTypeInfo = ({ type }) => {
<div>{'>'}</div>
</div>
);
case 'oneOfType':
return type.meta.types.map((type, idx) => (
<PropTypeInfo key={idx} type={type} />
));
default:
return null;
}
Expand Down

0 comments on commit bc5e17a

Please sign in to comment.