Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

address-generator

khaliliprf8ISC1.0.2TypeScript support: included

a lightweight package for generating wallet addresses in different networks

wallet, crypto, address, crypto-address, crypto-wallet, bitcoin, bitcoin-address, ethereum, ethereum-address, tron, tron-address

readme

address-generator

multi-currency wallet generator :

import wallet from "address-generator";
// generate legacy address
wallet.bitcoin.getP2pkhAddress(pubKey, testnet);
// generate native segwit address (bech32)
wallet.bitcoin.getBech32AddressFromPubKey(pubKey, testnet);
// generate taproot address
wallet.bitcoin.getTaprootAddress(pubKey, testnet);
// convert private key from Buffer to WIF format
wallet.bitcoin.getPrivateKeyInWifFormat(prvKey);
// get private key and return account address
wallet.bitcoin.retrieveAddressFromPvInWifFormat(wifPv);
// convert WIF private key to HEX
wallet.bitcoin.convertWifPvToHex(wifPv);
//generate ethereum address
wallet.ethereum.publicToAddress(pubKey);
// generate tron address
wallet.tron.publicToAddress(pubKey);