weth

1.0.4 • Public • Published

weth

call w-eth's smart contract

Super simple to use

Require and config:

const Weth = require('weth');
Weth.config({
    web3: web3, // your web3,
    contractAddress: contractAddress, // weth's contract address
    ownerAddress: ownerAddress // weth's owner address
});
 

withdraw

UNWRAP WETH to ETH:

Weth.withdraw(address, privateKeyAddress, amount);

deposit

WRAP ETH to WETH:

Weth.deposit(address, privateKeyAddress, amount);

Package Sidebar

Install

npm i weth

Weekly Downloads

2

Version

1.0.4

License

ISC

Unpacked Size

7.53 kB

Total Files

4

Last publish

Collaborators

  • lamtanphiho