Sure, when it's an identity function it's tedious (but there are websites that can generate the decoders in those cases). However, my experience is not that 80% are identity functions, it's closer to 10%. When I used Haskell, I would often "cheat" and accept an inadequate data structure for the business logic so Haskell could generate the data structures instead of writing my own decoders.
I've had the opposite experience, I would use automatic derivation everywhere, then immediately transform my data structures to business logic ones. Never once have I written my own decoder/encoder.
1
u/XzwordfeudzX Dec 08 '19
Sure, when it's an identity function it's tedious (but there are websites that can generate the decoders in those cases). However, my experience is not that 80% are identity functions, it's closer to 10%. When I used Haskell, I would often "cheat" and accept an inadequate data structure for the business logic so Haskell could generate the data structures instead of writing my own decoders.