Skip to content

Latest commit

 

History

History
36 lines (22 loc) · 865 Bytes

EXTEND.md

File metadata and controls

36 lines (22 loc) · 865 Bytes

1. Fork

See FORK.md for instructions.

2. Extend

git checkout extend

(cd go/extensions; go mod download)
(cd go/src; go clean --modcache; go mod download)

3. Add a type

See extensions/types.go for an example of how to declare a struct (in this case, a custom transaction message).

4. Register your type

See extensions/codec.go for an example of how to register the struct with the codec.

Interfaces can be registered the same way. See lib/codec.go for examples (all the registered types from the Cosmos SDK and Tendermint core).

5. Build

yarn setup

6. Test

See test/extensions.test.ts for an example of how to test marshaling and unmarshaling a struct.

yarn test