ethjs / ethjs-contract

A simple contract object for the Ethereum RPC layer.
MIT License
20 stars 28 forks source link

ability to pass arguments using an object #21

Open sulliwane opened 6 years ago

sulliwane commented 6 years ago

I think web3.js is providing this feature, instead of

mycontract.call(arg1, arg2, arg3, txObject);

allow to pass values using an object:

mycontract.call({ arg1: 'value1', arg2: 'value2', arg3: 'value3' }, txObject);

Input arg names are known from the ABI, so it would be super convenient to support that...

Thanks for your input on this!

sulliwane commented 6 years ago

So apparently I totally made up the fact that web3.js has implemented this, as nothing mentioned on their doc (https://web3js.readthedocs.io/en/1.0/web3-eth-contract.html#id12) :-)

But still, I'd be glad to have your opinion on this feature proposal! Many Thanks