From 9889c8f9e00707aeb7af4f79769ad6ad5b620f4d Mon Sep 17 00:00:00 2001 From: Olaf Tomalka Date: Sat, 30 Dec 2017 21:14:37 +0100 Subject: Fix ContractInstance new() not parsing properly new is a keyword in typescript and so if a function is called new(), tsc and for example Visual Studio Code don't regonize types for this function. The fix is to write this function in quotes --- packages/web3-typescript-typings/index.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/web3-typescript-typings/index.d.ts b/packages/web3-typescript-typings/index.d.ts index 677ed3e96..aa15ad86e 100644 --- a/packages/web3-typescript-typings/index.d.ts +++ b/packages/web3-typescript-typings/index.d.ts @@ -103,7 +103,7 @@ declare module 'web3' { interface Contract { at(address: string): A; - new(...args: any[]): A; + 'new'(...args: any[]): A; } interface FilterObject { -- cgit v1.2.3