aeson
aeson copied to clipboard
Pass runtime configuration to parseJSON
Is there a way to pass options, found at runtime, to parseJSON?
(Inspired by the SO question https://stackoverflow.com/q/44516946/1319998)
the Reifies example in the SO answer is the way to pass run-time information into instances. Universal approach for all instances, not only FromJSON.
@phadej According to the author of the answer in comments, Reifies can't be used to pass runtime information into decode, so it then, presumably, can't pass it to parseJSON... is that right?