Generate Ethereum CREATE2 addresses
const create2 =// From EIP test vectorsconst creatorAddress = '0xdeadbeef00000000000000000000000000000000'const salt = '0x0000000000000000000000000000000000000000000000000000000000000000'const initCode = '0x00'const address =// address === '0xb928f69bb1d91cd65274e3c79d8986362984fda3'
const resultAddress = create2(address, salt, initCode)
Generate Ethereum CREATE2 address. Arguments can either be in the usual
Ethereum hex encoded string form or
Buffers. Note that
address is the
address of the contract executing the
resultAddress as hex encoded string. Not checksum'ed, but this can be
eth-checksum or similar modules.
npm install eth-create2