Defaults to Bitcoin mainnet with English words.
const code = new Mnemonic();
const code = new Mnemonic();
code.toString();
// Example output: job shop small once merit ethics enhance direct lobster else copper cotton
import { ltc } from '@hyperbitjs/chains';
const code = new Mnemonic({ network: ltc.mainnet });
code.toString();
const code = new Mnemonic({ language: 'spanish' });
const isValid = Mnemonic.isValid(code.toString());
const passphrase = '';
const code = new Mnemonic({ passphrase });
const seedBuffer = code.toSeed();
const code = new Mnemonic();
const hdPrivateKey1 = code.getHDPrivateKey();
const words = Mnemonic.words('english');
const phrase = Mnemonic.generateMnemonic('english');
const code = new Mnemonic();
const addresses = code.generateAddresses();
// Example output: [{ external: {...}, change: {...} }]
console.log(code.accounts);
// Example output: { 0: {}, 1: {} }
console.log(code.accounts['0']);
// Example output: { external: {...}, change: {...} }
console.log(code.accounts['0'].external.get(1));
// Example output:
// privateKey: '';
// address: '';
// path: '';
// wif: '';