Great Question! You can checkout an example here <https://gist.github.com/john-kelly/00424de66be03d9bbb07795b11c39a48>. It builds off of the example presented in the docs.
Currently, the library does not support representing relationships in the Resource definition, however, the library *does *support representing the relationships in the queries (see example). I'm not yet sure the best way / whether it will be possible to represent the relationships in the Resource definition. Would love to chat if you have any ideas! On Friday, October 21, 2016 at 1:25:10 AM UTC-7, Peter Damoc wrote: > > Hi John, > > The project you linked to looks great. > How do you deal with references? (entities referencing other entities) > > > > On Thu, Oct 20, 2016 at 9:19 PM, John Kelly <[email protected] > <javascript:>> wrote: > >> I'm sorry to link drop, but I've been doing a bit of work on a library to >> remove some of the boilerplate when writing client code for a REST API. The >> library is currently locked in / specific to what is called PostgREST, but >> I imagine that the patterns could be applied to any REST backend. Check it >> out: https://github.com/john-kelly/elm-postgrest/ >> >> The core idea is to remove the boilerplate of always having to define >> encoder, decoder and schema. Would love to chat. >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Elm Discuss" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> > > > > -- > There is NO FATE, we are the creators. > blog: http://damoc.ro/ > -- You received this message because you are subscribed to the Google Groups "Elm Discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
