Safe Haskell | None |
---|---|
Language | Haskell2010 |
This module implements a generator for JSON serialisers and parsers of arbitrary elm types.
It is highly recommended to either only use the functions of Elm.Module, or to use the functions in this module
after having modified the ETypeDef
arguments with functions such as defaultAlterations
.
The reason is that Elm types might have an equivalent on the Haskell side and should be converted (ie. Text
-> String
, Vector
-> List
).
- jsonParserForDef :: ETypeDef -> String
- jsonSerForDef :: ETypeDef -> String
Documentation
jsonParserForDef :: ETypeDef -> String Source
Compile a JSON parser for an Elm type definition
jsonSerForDef :: ETypeDef -> String Source
Compile a JSON serializer for an Elm type definition TODO: handle the omit null case