SalomonBrys / Kotson

Kotlin bindings for JSON manipulation via Gson
MIT License
709 stars 37 forks source link

Serializing delegates #40

Open rnett opened 6 years ago

rnett commented 6 years ago

It would be nice if there was a option (or if it was the default behavior) to evaluate delegates when serializing objects.

For example, val jumps by json.byInt would serialize to something like "jumps": 3.

This would extremely helpful when using a class that generated from json using the json delegates (byInt, etc). Right now, using these requires a custom serializer to be serializable properly.