gmsg

Package Version Hex Docs CI

MessagePack encoding/decoding for Gleam.

Install

gleam add gmsg@1

Quick start

import gmsg
import gleam/io

let data = gmsg.pack_string("hello")
let Ok(bin) = gmsg.to_bit_array(data)
io.println(bit_array.inspect(bin))

// returns Dynamic
let Ok(dynamic) =
  gmsg.parse(bin, using: decode.string)

Further documentation can be found at https://hexdocs.pm/gmsg.

Development

gleam test  # Run the tests

License

Apache-2.0 © HeroesLament

Search Document