gblake2

Package Version Hex Docs

Gleam bindings for the Elixir blake2 package.

gleam add gblake2@1
import gblake2

pub fn main() -> Nil {
  "Nimiq rocks!"
  |> bit_array.from_string()
  // Hash a bitarray into a 32-byte hash
  |> gblake2.hash2b(32)
  |> bit_array.base16_encode()
  // -> "E493EE724B7D9D0AFE079DD7236DA36AB9DC5EF446AC16E52F232CF38A2CCB2F"
}

Development

gleam test  # Run the tests
Search Document