I want to add persistence to my app. Only parts of the model need to be 
saved. For this, I need a way to decode/encode the model to and fro' JSON.

My original idea was to have a `-- JSON` section in each elm architecture 
component. Parent components would use their children's decode/encode 
methods to write their own. I ran into some problems doing it this way, 
namely code duplication between the `init` and `decode` methods and the 
handling of `Cmd`s. Is there a better way to do it or any general advice?

-- 
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.

Reply via email to