Skip to main content
added 2 characters in body
Source Link

The solution is that you import hdkey from the ethereumethereumjs-wallet library. hdkey is being exported and it is not the default export.

const {hdkey} = require('ethereumjs-wallet');

const mnemonic = bip39.generateMnemonic();
const seed = bip39.mnemonicToSeedSync(mnemonic);
const hdWallet = hdkey.fromMasterSeed(seed);

The solution is that you import hdkey from the ethereum-wallet library. hdkey is being exported and it is not the default export.

const {hdkey} = require('ethereumjs-wallet');

const mnemonic = bip39.generateMnemonic();
const seed = bip39.mnemonicToSeedSync(mnemonic);
const hdWallet = hdkey.fromMasterSeed(seed);

The solution is that you import hdkey from the ethereumjs-wallet library. hdkey is being exported and it is not the default export.

const {hdkey} = require('ethereumjs-wallet');

const mnemonic = bip39.generateMnemonic();
const seed = bip39.mnemonicToSeedSync(mnemonic);
const hdWallet = hdkey.fromMasterSeed(seed);
Source Link

The solution is that you import hdkey from the ethereum-wallet library. hdkey is being exported and it is not the default export.

const {hdkey} = require('ethereumjs-wallet');

const mnemonic = bip39.generateMnemonic();
const seed = bip39.mnemonicToSeedSync(mnemonic);
const hdWallet = hdkey.fromMasterSeed(seed);