Skip to content

Instantly share code, notes, and snippets.

@tina1998612
Created January 20, 2018 03:54
Show Gist options
  • Save tina1998612/da767c5fc78f1db5d2ee463048a09ef7 to your computer and use it in GitHub Desktop.
Save tina1998612/da767c5fc78f1db5d2ee463048a09ef7 to your computer and use it in GitHub Desktop.
function functionSignatureFromAbi(abiArray) {
let functionSignatures = [];
for (i in abiArray) {
let abi = abiArray[i];
let functionSignature = abi.name + '(' + abi.inputs.map((input) => input.type + ' ' + input.name).join(', ') + ')';
functionSignatures.push(functionSignature);
// console.log(functionSignature);
}
return functionSignatures;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment