Hello, I am a big fan of Spring, but an even bigger fan of Kotlin Multiplatform, especially the common code part. However, for entities and persistence this is not possible, since the annotations are JVM-world only. What would be an optimal way to share the entities between platforms?
One way would be to just accept it and write
fromDataEntity
and
toDataEntity
helper functions for every common data class which is to be persisted. But that is a lot of boilerplate I suppose.
Any other ideas?
r
Robert Jaros
08/19/2022, 8:10 AM
You can use `expect`/`actual` for annotations in common code.