Registering a JsonAdapter directly should only be used for the most trivial adapters. Otherwise you probably want to prefer using `@ToJson`/`@FromJson` or
JsonAdapter.Factory
s
Sam Garfinkel
04/10/2020, 2:31 PM
Thanks, Jake!
Sam Garfinkel
04/10/2020, 2:37 PM
Does Kotlin Codegen not generate the
JsonAdapter.Factory
implementation?
j
jw
04/10/2020, 2:37 PM
I have no idea. I use kotlinx.serialization for JSON in Kotlin.
s
Sam Garfinkel
04/10/2020, 2:39 PM
Yeah I would normally but I need my deserialized JSON to be injected with stuff (primarily my rest api services) as it’s json-ld and I was having a nightmare getting my custom serializers that injects the extra stuff to be used.