diff options
author | Fabio Berger <me@fabioberger.com> | 2018-04-11 15:53:13 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2018-04-11 15:53:13 +0800 |
commit | 7d9c6eafbfd8434c92737a0e9edf8e610984ac90 (patch) | |
tree | 7383bb2110215a3502d2bd4302072a7dc48275c1 /packages/react-docs/src/components | |
parent | de6f757ec821c6e735e0f5e8c2e5621b57c02f55 (diff) | |
download | dexon-sol-tools-7d9c6eafbfd8434c92737a0e9edf8e610984ac90.tar dexon-sol-tools-7d9c6eafbfd8434c92737a0e9edf8e610984ac90.tar.gz dexon-sol-tools-7d9c6eafbfd8434c92737a0e9edf8e610984ac90.tar.bz2 dexon-sol-tools-7d9c6eafbfd8434c92737a0e9edf8e610984ac90.tar.lz dexon-sol-tools-7d9c6eafbfd8434c92737a0e9edf8e610984ac90.tar.xz dexon-sol-tools-7d9c6eafbfd8434c92737a0e9edf8e610984ac90.tar.zst dexon-sol-tools-7d9c6eafbfd8434c92737a0e9edf8e610984ac90.zip |
Add support for nested methods within type declarations. Make sure they render without a callPath.
Diffstat (limited to 'packages/react-docs/src/components')
-rw-r--r-- | packages/react-docs/src/components/interface.tsx | 3 | ||||
-rw-r--r-- | packages/react-docs/src/components/type.tsx | 1 |
2 files changed, 1 insertions, 3 deletions
diff --git a/packages/react-docs/src/components/interface.tsx b/packages/react-docs/src/components/interface.tsx index 541e164e3..bdfdf47c4 100644 --- a/packages/react-docs/src/components/interface.tsx +++ b/packages/react-docs/src/components/interface.tsx @@ -19,7 +19,7 @@ export function Interface(props: InterfaceProps) { return ( <span key={`property-${property.name}-${property.type}-${type.name}`}> {property.name}:{' '} - {property.type.typeDocType !== TypeDocTypes.Reflection ? ( + {property.type && property.type.typeDocType !== TypeDocTypes.Reflection ? ( <Type type={property.type} sectionName={props.sectionName} docsInfo={props.docsInfo} /> ) : ( <Signature @@ -27,7 +27,6 @@ export function Interface(props: InterfaceProps) { returnType={property.type.method.returnType} parameters={property.type.method.parameters} typeParameter={property.type.method.typeParameter} - callPath={property.type.method.callPath} sectionName={props.sectionName} shouldHideMethodName={true} shouldUseArrowSyntax={true} diff --git a/packages/react-docs/src/components/type.tsx b/packages/react-docs/src/components/type.tsx index fd4562ce3..2b7b49672 100644 --- a/packages/react-docs/src/components/type.tsx +++ b/packages/react-docs/src/components/type.tsx @@ -109,7 +109,6 @@ export function Type(props: TypeProps): any { returnType={type.method.returnType} parameters={type.method.parameters} typeParameter={type.method.typeParameter} - callPath={type.method.callPath} sectionName={props.sectionName} shouldHideMethodName={true} shouldUseArrowSyntax={true} |