UNPKG

433 BJavaScriptView Raw
1import { convert as tsConvert } from './typescript';
2import { convert as flowConvert } from './flow';
3import { convert as propTypesConvert } from './proptypes';
4export const convert = docgenInfo => {
5 const {
6 type,
7 tsType,
8 flowType
9 } = docgenInfo;
10 if (type != null) return propTypesConvert(type);
11 if (tsType != null) return tsConvert(tsType);
12 if (flowType != null) return flowConvert(flowType);
13 return null;
14};
\No newline at end of file