1.0.0 • Published 5 years ago

@ostdotcom/xweb3 v1.0.0

Weekly downloads
2
License
LGPL-3.0
Repository
github
Last release
5 years ago

xweb3

Ethereum interaction layer by extending web3.js Build Status npm version

Install

npm install @ostdotcom/xweb3 --save

OSTWeb3 Usage

const xweb3 = require('@ostdotcom/xweb3'), 
    wsEndPoint = "ws://127.0.0.1:8546",
    rpcEndPoint = "http://127.0.0.1:8545";

// The below instance of web3 uses OstWSProvider.
// OstWSProvider automatically tries to reconnect when connection is broken.
let wsWeb3 = new xweb3.OstWeb3( wsEndPoint );

// The below instance is same as new Web3( rpcEndPoint );
let rpcWeb3 = new xweb3.OstWeb3( rpcEndPoint );