diff options
author | Kadinsky <kandinsky454@protonmail.ch> | 2018-10-18 02:01:29 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-18 02:01:29 +0800 |
commit | 5ec4b27200297708298deca97603849a37b2f66a (patch) | |
tree | 96c28898329c3bf786a08549384f2de79d0903f8 /packages/sol-doc/src/sol_doc.ts | |
parent | b2012bf1610eda65afe180b04df6c9ee8f5dc659 (diff) | |
parent | bdae4ba2a2c9b7b3b41c352c628cb11cd4a1f295 (diff) | |
download | dexon-sol-tools-5ec4b27200297708298deca97603849a37b2f66a.tar dexon-sol-tools-5ec4b27200297708298deca97603849a37b2f66a.tar.gz dexon-sol-tools-5ec4b27200297708298deca97603849a37b2f66a.tar.bz2 dexon-sol-tools-5ec4b27200297708298deca97603849a37b2f66a.tar.lz dexon-sol-tools-5ec4b27200297708298deca97603849a37b2f66a.tar.xz dexon-sol-tools-5ec4b27200297708298deca97603849a37b2f66a.tar.zst dexon-sol-tools-5ec4b27200297708298deca97603849a37b2f66a.zip |
Merge pull request #1145 from 0xProject/refactorSchemasToJSON
Move json-schema schemas to JSON files
Diffstat (limited to 'packages/sol-doc/src/sol_doc.ts')
-rw-r--r-- | packages/sol-doc/src/sol_doc.ts | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/packages/sol-doc/src/sol_doc.ts b/packages/sol-doc/src/sol_doc.ts index 138882c92..686e9ca34 100644 --- a/packages/sol-doc/src/sol_doc.ts +++ b/packages/sol-doc/src/sol_doc.ts @@ -324,19 +324,25 @@ export class SolDoc { switch (abiDefinition.type) { case 'constructor': docSection.constructors.push( - this._genConstructorDoc(contractName, abiDefinition, compiledContract.devdoc), + // tslint:disable-next-line:no-unnecessary-type-assertion + this._genConstructorDoc(contractName, abiDefinition as ConstructorAbi, compiledContract.devdoc), ); break; case 'event': - (docSection.events as Event[]).push(SolDoc._genEventDoc(abiDefinition)); + // tslint:disable-next-line:no-unnecessary-type-assertion + (docSection.events as Event[]).push(SolDoc._genEventDoc(abiDefinition as EventAbi)); // note that we're not sending devdoc to this._genEventDoc(). // that's because the type of the events array doesn't have any fields for documentation! break; case 'function': - docSection.methods.push(this._genMethodDoc(abiDefinition, compiledContract.devdoc)); + // tslint:disable-next-line:no-unnecessary-type-assertion + docSection.methods.push(this._genMethodDoc(abiDefinition as MethodAbi, compiledContract.devdoc)); break; case 'fallback': - docSection.methods.push(SolDoc._genFallbackDoc(abiDefinition, compiledContract.devdoc)); + // tslint:disable-next-line:no-unnecessary-type-assertion + docSection.methods.push( + SolDoc._genFallbackDoc(abiDefinition as FallbackAbi, compiledContract.devdoc), + ); break; default: throw new Error( |