@rei-network/wallet
v0.1.1
Published
[![NPM Version](https://img.shields.io/npm/v/@rei-network/wallet)](https://www.npmjs.org/package/@rei-network/wallet) ![License](https://img.shields.io/npm/l/@rei-network/wallet)
Downloads
21
Readme
@rei-network/wallet
Wallet based on ethereumjs-wallet
, for managing local accounts
INSTALL
npm install @rei-network/wallet
USAGE
const manager = new AccountManager("/root/.rei/keystore");
// new account
const { address } = await manager.newAccount("passphrase");
console.log("new address:", address);
// unlock account
await manager.unlock(address, "passphrase");
// get account private key
console.log(manager.getPrivateKey(address).toString("hex"));