Encode to and decode from bytecode easily with abi
package. Usage is similar to Solididy's abi.encode
, abi.encodePacked
, and abi.decode
functions.
go get github.com/omnes-tech/abi
Encode functions:
Encode
EncodePacked
EncodeSelector
EncodeWithSignature
EncodeWithSelector
Decode functions:
Decode
DecodePacked
DecodeWithSignature
DecodeWithSelector