solselector
v1.0.4
Published
Get The 4 byte Selector/Method Signature of any function
Downloads
7
Maintainers
Readme
solselector
Get The 4 byte Selector/Method Signature of any function
Installation
Install dependencies
npm install solselector
Key Functions
let selector = require("solselector");
//full keccak256 hash
selector.keccak256("balanceOf");
//get 4byte selector
selector.getSelector("balanceOf()");
//get 4byte selector - multi arguments
selector.getMultiSelector("balanceOf()", "transferFrom(address,uint256)");
//get 4byte selector - multi array arguments
selector.getMultiSelector(["balanceOf()", "transferFrom(address,uint256)", "deposit()"]);