Substrate-based blockchains use the SCALE
codec to encode data, including the metadata that describes the chain.
The purpose of this project is to learn more about the SCALE codec by using it to decode
v11
of Substrate metadata.
In order to use this project, you must first install its dependencies:
$ yarn
Then, use the provided start
command to fetch the latest metadata from wss://kusama-rpc.polkadot.io/
and write the
raw metadata to metadata.scale
& the parsed metadata to metadata.json
.
$ yarn start
All of the code for this project is in a single file, index.js
. Take a look and see the SCALE codec in
action 🤓