diff options
author | Nikita Galkin <nikita@galk.in> | 2018-06-23 21:32:07 +0800 |
---|---|---|
committer | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-06-27 14:26:48 +0800 |
commit | 84bd54ba4025a33f4e311ec66d81d58b45e54d6b (patch) | |
tree | b3c96c40c8fdbe22248a10764c1346dbfe0b4daf /packages/typescript-typings/types/web3-provider-engine/index.d.ts | |
parent | 73c36fe2d20c0e477458e6c07b837b08f8d424c6 (diff) | |
download | dexon-0x-contracts-84bd54ba4025a33f4e311ec66d81d58b45e54d6b.tar dexon-0x-contracts-84bd54ba4025a33f4e311ec66d81d58b45e54d6b.tar.gz dexon-0x-contracts-84bd54ba4025a33f4e311ec66d81d58b45e54d6b.tar.bz2 dexon-0x-contracts-84bd54ba4025a33f4e311ec66d81d58b45e54d6b.tar.lz dexon-0x-contracts-84bd54ba4025a33f4e311ec66d81d58b45e54d6b.tar.xz dexon-0x-contracts-84bd54ba4025a33f4e311ec66d81d58b45e54d6b.tar.zst dexon-0x-contracts-84bd54ba4025a33f4e311ec66d81d58b45e54d6b.zip |
Improve 'web3-provider-engine' typings
Diffstat (limited to 'packages/typescript-typings/types/web3-provider-engine/index.d.ts')
-rw-r--r-- | packages/typescript-typings/types/web3-provider-engine/index.d.ts | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/packages/typescript-typings/types/web3-provider-engine/index.d.ts b/packages/typescript-typings/types/web3-provider-engine/index.d.ts index 1733f2731..72ef434a7 100644 --- a/packages/typescript-typings/types/web3-provider-engine/index.d.ts +++ b/packages/typescript-typings/types/web3-provider-engine/index.d.ts @@ -1,6 +1,12 @@ declare module 'web3-provider-engine' { import { Provider, JSONRPCRequestPayload, JSONRPCResponsePayload } from 'ethereum-types'; + interface Web3ProviderEngineOptions { + pollingInterval?: number; + blockTracker?: any; + blockTrackerProvider?: any; + } class Web3ProviderEngine implements Provider { + constructor(options?: Web3ProviderEngineOptions); public on(event: string, handler: () => void): void; public send(payload: JSONRPCRequestPayload): void; public sendAsync( @@ -8,7 +14,9 @@ declare module 'web3-provider-engine' { callback: (error: null | Error, response: JSONRPCResponsePayload) => void, ): void; public addProvider(provider: any): void; - public start(): void; + // start block polling + public start(callback?: () => void): void; + // stop block polling public stop(): void; } export = Web3ProviderEngine; |