You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Now let's say we'd like to operate on the train number (simpler than the date for illustration purposes), delivered to us by the grace of German engineering in string format. Reformatting according to define-json-mapping is a little tedious but overall worth the convenience/granularity tradeoff in my opinion. The painful part is that we also have to manually map any nested records, which isn't related to the problem we're working on.
Am I just missing something simple? Is there any reason why define-json-type can't support the scm->value and value->scm field specifications? Have you considered using keywords over positional parameters, or would you be open to that change in the future? Thanks again for your support.
The text was updated successfully, but these errors were encountered:
hi @vintnes ! Yes, it's definitely a little bit more painful. I added define-json-type to be able to define simple JSON objects in a very simple way, but when it comes to flexibility you run into the issue you are having now. It might be worth adding keyword arguments there as you suggest, for example:
Hi Aleix. Thank you for this solid library I use daily.
It's kind of painful when a JSON type with a nested record type needs to implement some value conversion.
Example
Now let's say we'd like to operate on the train number (simpler than the date for illustration purposes), delivered to us by the grace of German engineering in string format. Reformatting according to
define-json-mapping
is a little tedious but overall worth the convenience/granularity tradeoff in my opinion. The painful part is that we also have to manually map any nested records, which isn't related to the problem we're working on.Am I just missing something simple? Is there any reason why
define-json-type
can't support thescm->value
andvalue->scm
field specifications? Have you considered using keywords over positional parameters, or would you be open to that change in the future? Thanks again for your support.The text was updated successfully, but these errors were encountered: