diff options
author | Fabio Berger <me@fabioberger.com> | 2018-09-26 00:34:22 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2018-09-26 00:34:22 +0800 |
commit | b40861747b73bb9a0826853751b7caa5cbf085ae (patch) | |
tree | 4c2d306da6265bacf1d476afe0531e38f25f287c /packages/react-docs/src/utils | |
parent | b73df28454bf72c0e68b1150ca6ee0ea3ead1382 (diff) | |
download | dexon-sol-tools-b40861747b73bb9a0826853751b7caa5cbf085ae.tar dexon-sol-tools-b40861747b73bb9a0826853751b7caa5cbf085ae.tar.gz dexon-sol-tools-b40861747b73bb9a0826853751b7caa5cbf085ae.tar.bz2 dexon-sol-tools-b40861747b73bb9a0826853751b7caa5cbf085ae.tar.lz dexon-sol-tools-b40861747b73bb9a0826853751b7caa5cbf085ae.tar.xz dexon-sol-tools-b40861747b73bb9a0826853751b7caa5cbf085ae.tar.zst dexon-sol-tools-b40861747b73bb9a0826853751b7caa5cbf085ae.zip |
Properly render function generic types that don't extend another type
Diffstat (limited to 'packages/react-docs/src/utils')
-rw-r--r-- | packages/react-docs/src/utils/typedoc_utils.ts | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/packages/react-docs/src/utils/typedoc_utils.ts b/packages/react-docs/src/utils/typedoc_utils.ts index f44945369..e3e9c11fb 100644 --- a/packages/react-docs/src/utils/typedoc_utils.ts +++ b/packages/react-docs/src/utils/typedoc_utils.ts @@ -419,7 +419,10 @@ export class TypeDocUtils { return func; } private _convertTypeParameter(entity: TypeDocNode, sectionName: string): TypeParameter { - const type = this._convertType(entity.type, sectionName); + let type; + if (!_.isUndefined(entity.type)) { + type = this._convertType(entity.type, sectionName); + } const parameter = { name: entity.name, type, |