I'm having a problem in casting plain JSON objects...
# javascript
g
I'm having a problem in casting plain JSON objects coming from fetch requests to actual JS classes with methods from Kotlin such as
.toString(), .copy(), constructor
, because the actual class implementations in the generated .js file append an underscore to all the field names, for example id becomes _id. From a thread in #javascript
Nevermind, I figured out that I can instantiate those JS classes with a data class constructor from Kotlin