How can I decide the order of the proerties in DhallToJson

Im searching a way to be able to move one of a Json object’s property to end base on its name, what will be the best way to achieve it ?

Using the haskell library, dhallToJSON gives you a JSON Value you can modify before printing out.

Thanks for the response, I think I was not specific enough let me try to explain better.
I am converting json to dhall. I need the dhall’s record types to have their property (or one specific one) be in a custom order (not alphabetic). Is there any way I can organize the properties of the dhall’s record types in a specific order?

@countoren: It might be possible to fix json-to-dhall to preserve field order. Could you open an issue against the dhall-haskell project to track this request: https://github.com/dhall-lang/dhall-haskell/issues

done

Thanks

1 Like