A compact text encoding for ints, used in sourcemaps.
gleam add vlq@1import vlq
pub fn main() -> Nil {
assert vlq.encode64([0, 0, 16, 1]) == "AAgBC"
assert vlq.decode64("AAgBC") == Ok([0, 0, 16, 1])
}Documentation can be found at https://hexdocs.pm/vlq.
Thank you to Martin Janiczek's elm-vlq, which was a reference for this library.