Ethereum 使用web3.js v0.2.6创建帐户
因此,每次我尝试使用web3创建帐户时,总是会出现错误,比如web3版本错误,我应该切换到v1.0.0 我使用此命令安装web3Ethereum 使用web3.js v0.2.6创建帐户,ethereum,web3js,ether,Ethereum,Web3js,Ether,因此,每次我尝试使用web3创建帐户时,总是会出现错误,比如web3版本错误,我应该切换到v1.0.0 我使用此命令安装web3 npm install ethereum/web3.js --save 我尝试使用这些命令创建帐户,但始终存在不匹配 web3.eth.accounts.create(); web3.eth.personal.newAccount('!@superpassword') .then(console.log); 即使我安装了 npm install web3-
npm install ethereum/web3.js --save
我尝试使用这些命令创建帐户,但始终存在不匹配
web3.eth.accounts.create();
web3.eth.personal.newAccount('!@superpassword')
.then(console.log);
即使我安装了
npm install web3-eth-account --save
npm install web3-eth-personal --save
有人能帮我吗?答案是
let a=web3.personal.newAccount('!@superpassword')
web3.js
web3.personal
。见文件。