Socket
Socket
Sign inDemoInstall

web3-eth-contract

Package Overview
Dependencies
Maintainers
2
Versions
440
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

web3-eth-contract - npm Package Compare versions

Comparing version 1.2.1 to 1.2.2

types/index.d.ts

25

package.json
{
"name": "web3-eth-contract",
"version": "1.2.1",
"version": "1.2.2",
"description": "Web3 module to interact with Ethereum smart contracts.",

@@ -10,13 +10,22 @@ "repository": "https://github.com/ethereum/web3.js/tree/1.x/packages/web3-eth-contract",

},
"types": "types/index.d.ts",
"scripts": {
"dtslint": "dtslint types --onlyTestTsNext"
},
"main": "src/index.js",
"dependencies": {
"@types/bn.js": "^4.11.4",
"underscore": "1.9.1",
"web3-core": "1.2.1",
"web3-core-helpers": "1.2.1",
"web3-core-method": "1.2.1",
"web3-core-promievent": "1.2.1",
"web3-core-subscriptions": "1.2.1",
"web3-eth-abi": "1.2.1",
"web3-utils": "1.2.1"
"web3-core": "1.2.2",
"web3-core-helpers": "1.2.2",
"web3-core-method": "1.2.2",
"web3-core-promievent": "1.2.2",
"web3-core-subscriptions": "1.2.2",
"web3-eth-abi": "1.2.2",
"web3-utils": "1.2.2"
},
"devDependencies": {
"definitelytyped-header-parser": "^1.0.1",
"dtslint": "0.4.2"
}
}

@@ -27,3 +27,2 @@ # web3-eth-contract

## Usage

@@ -45,6 +44,10 @@

[docs]: http://web3js.readthedocs.io/en/1.0/
[repo]: https://github.com/ethereum/web3.js
## Types
All the typescript typings are placed in the types folder.
[docs]: http://web3js.readthedocs.io/en/1.0/
[repo]: https://github.com/ethereum/web3.js

@@ -183,2 +183,8 @@ /*

var defaultBlock = this.constructor.defaultBlock || 'latest';
this.transactionBlockTimeout = this.constructor.transactionBlockTimeout;
this.transactionConfirmationBlocks = this.constructor.transactionConfirmationBlocks;
this.transactionPollingTimeout = this.constructor.transactionPollingTimeout;
this.defaultChain = this.constructor.defaultChain;
this.defaultHardfork = this.constructor.defaultHardfork;
this.defaultCommon = this.constructor.defaultCommon;

@@ -532,12 +538,12 @@ Object.defineProperty(this, 'defaultAccount', {

var event = (_.isString(args[0])) ? args[0] : 'allevents';
event = (event.toLowerCase() === 'allevents') ? {
var eventName = (_.isString(args[0])) ? args[0] : 'allevents';
var event = (eventName.toLowerCase() === 'allevents') ? {
name: 'ALLEVENTS',
jsonInterface: this.options.jsonInterface
} : this.options.jsonInterface.find(function (json) {
return (json.type === 'event' && (json.name === event || json.signature === '0x'+ event.replace('0x','')));
return (json.type === 'event' && (json.name === eventName || json.signature === '0x'+ eventName.replace('0x','')));
});
if (!event) {
throw new Error('Event "' + event.name + '" doesn\'t exist in this contract.');
throw new Error('Event "' + eventName + '" doesn\'t exist in this contract.');
}

@@ -896,2 +902,8 @@

defaultBlock: _this._parent.defaultBlock,
transactionBlockTimeout: _this._parent.transactionBlockTimeout,
transactionConfirmationBlocks: _this._parent.transactionConfirmationBlocks,
transactionPollingTimeout: _this._parent.transactionPollingTimeout,
defaultCommon: _this._parent.defaultCommon,
defaultChain: _this._parent.defaultChain,
defaultHardfork: _this._parent.defaultHardfork,
extraFormatters: extraFormatters

@@ -898,0 +910,0 @@ })).createFunction();

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc