Encoding helpers for IOV projects


198492.5.0a year ago3 years agoMinified + gzip package size for @iov/encoding in KB



npm version

This package is an extension to the JavaScript standard library that is not bound to IOV products. It provides basic hex/base64/ascii/integer encoding to Uint8Array that doesn't rely on Buffer and also provides better error messages on invalid input.

Convert between bech32 and hex addresses

>> Bech32.encode("tiov", fromHex("1234ABCD0000AA0000FFFF0000AA00001234ABCD"))
>> toHex(Bech32.decode("tiov1zg62hngqqz4qqq8lluqqp2sqqqfrf27dzrrmea").data)

API Documentation



This package is part of the IOV-Core repository, licensed under the Apache License 2.0 (see NOTICE and LICENSE).

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.