/restruct

An Elixir library for ensuring structs match their current definition.

Primary LanguageElixirApache License 2.0Apache-2.0

Restruct Hex Version Hex Docs CI Status

An Elixir library for ensuring structs match their current definition.

This is useful if you serialize structs using :erlang.term_to_binary/1 or are sending structs between nodes running different code versions.

Installation

The package can be installed by adding restruct to your list of dependencies in mix.exs:

def deps do
  [
    {:restruct, "~> 0.1.0"}
  ]
end

Documentation can be generated with ExDoc and published on HexDocs. Once published, the docs can be found at https://hexdocs.pm/restruct.