blockchain - web3 - 使用metamask 调用某个contract 的方法
访问量: 10
refer to: https://ethereum.stackexchange.com/questions/25431/metamask-how-to-access-call-deployed-contracts-functions-using-metamask
// Get the contract instance using your contract's abi and address: const contractInstance = web3.eth.contract(abi).at(contractAddress); // Call a function of the contract: contractInstance.someFunction({ from: sender, value: someValue, gas: limit }, (err, res) => { /** do something with results **/ });