aboutsummaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
Diffstat (limited to 'packages')
-rw-r--r--packages/web3-typescript-typings/index.d.ts15
1 files changed, 11 insertions, 4 deletions
diff --git a/packages/web3-typescript-typings/index.d.ts b/packages/web3-typescript-typings/index.d.ts
index d50bd6b93..7e13b4793 100644
--- a/packages/web3-typescript-typings/index.d.ts
+++ b/packages/web3-typescript-typings/index.d.ts
@@ -46,8 +46,15 @@ declare module 'web3' {
type FunctionAbi = MethodAbi|ConstructorAbi|FallbackAbi;
+ enum AbiType {
+ Function = 'function',
+ Constructor = 'constructor',
+ Event = 'event',
+ Fallback = 'fallback',
+ }
+
interface MethodAbi {
- type: 'function';
+ type: AbiType.Function;
name: string;
inputs: FunctionParameter[];
outputs: FunctionParameter[];
@@ -56,13 +63,13 @@ declare module 'web3' {
}
interface ConstructorAbi {
- type: 'constructor';
+ type: AbiType.Constructor;
inputs: FunctionParameter[];
payable: boolean;
}
interface FallbackAbi {
- type: 'fallback';
+ type: AbiType.Fallback;
payable: boolean;
}
@@ -73,7 +80,7 @@ declare module 'web3' {
}
interface EventAbi {
- type: 'event';
+ type: AbiType.Event;
name: string;
inputs: EventParameter[];
anonymous: boolean;