Syrup format encoder and decoder
| src | constructors and single module lib | |
| test | constructors and single module lib | |
| .gitignore | initial commit | |
| gleam.toml | constructors and single module lib | |
| LICENSE | initial commit | |
| manifest.toml | initial commit | |
| README.md | constructors and single module lib | |
| zoo.bin | initial commit | |
gleerup
Simple Syrup encoder and decoder for Gleam.
gleam add gleerup
importgleeruppubfnmain()->Nil{letinput=<<"{3\"age30+4\"name5\"Alice7\"another[1+2+3+]7\"isAlivet}">>letresult=gleerup.decode(input)|>default_valueassertgleerup.dictionary(dict.from_list([#(gleerup.str("age"),gleerup.int(30)),#(gleerup.str("name"),gleerup.str("Alice")),#(gleerup.str("another"),gleerup.sequence([gleerup.int(1),gleerup.int(2),gleerup.int(3),]),),#(gleerup.str("isAlive"),gleerup.bool(True)),]),)==result}Further documentation can be found at https://hexdocs.pm/gleerup.
Development
gleam run # Run the project
gleam test # Run the tests