ethereumjs-tx: Provides its own types (#39621)

This commit is contained in:
Alexander T
2019-11-01 10:36:14 -07:00
committed by Jesse Trinity
parent 7130ce750b
commit f86d2583cf
5 changed files with 6 additions and 58 deletions
+6
View File
@@ -1062,6 +1062,12 @@
"sourceRepoURL": "https://github.com/sindresorhus/escape-string-regexp",
"asOfVersion": "2.0.0"
},
{
"libraryName": "ethereumjs-tx",
"typingsPackageName": "ethereumjs-tx",
"sourceRepoURL": "https://github.com/ethereumjs/ethereumjs-tx",
"asOfVersion": "2.0.0"
},
{
"libraryName": "eventemitter2",
"typingsPackageName": "eventemitter2",
@@ -1,4 +0,0 @@
import EthereumjsTx = require('ethereumjs-tx');
const txParams = {};
const tx = new EthereumjsTx(txParams);
-37
View File
@@ -1,37 +0,0 @@
// Type definitions for ethereumjs-tx 1.0
// Project: https://github.com/ethereumjs/ethereumjs-tx
// Definitions by: Leonid Logvinov <https://github.com/LogvinovLeon>
// David Mihal <https://github.com/dmihal>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
/// <reference types="node"/>
import BN = require("bn.js");
declare class EthereumTx {
raw: Buffer[];
r: Buffer;
s: Buffer;
v: Buffer;
nonce: Buffer;
gasPrice: Buffer;
gasLimit: Buffer;
to: Buffer;
value: Buffer;
data: Buffer;
serialize(): Buffer;
sign(buffer: Buffer): void;
toJSON(): string | string[];
toCreationAddress(): boolean;
hash(includeSignature?: boolean): Buffer;
getChainId(): Buffer;
getSenderAddress(): Buffer;
getSenderPublicKey(): Buffer;
verifySignature(): boolean;
getDataFee(): BN;
getBaseFee(): BN;
getUpfrontCost(): BN;
validate(stringError?: boolean): string | boolean;
constructor(txParams: any);
}
export = EthereumTx;
-16
View File
@@ -1,16 +0,0 @@
{
"compilerOptions": {
"module": "commonjs",
"lib": ["es6"],
"noImplicitAny": true,
"noImplicitThis": true,
"strictNullChecks": true,
"strictFunctionTypes": true,
"baseUrl": "../",
"typeRoots": ["../"],
"types": [],
"noEmit": true,
"forceConsistentCasingInFileNames": true
},
"files": ["index.d.ts", "ethereumjs-tx-tests.ts"]
}
-1
View File
@@ -1 +0,0 @@
{ "extends": "dtslint/dt.json" }