icerockdev / moko-kswift

Swift-friendly api generator for Kotlin/Native frameworks
https://moko.icerock.dev
Apache License 2.0
348 stars 21 forks source link

Add a feature to generate Swift enums with associated values #71

Open hbmartin opened 1 year ago

hbmartin commented 1 year ago
associated enum diagram

https://app.diagrams.net/#G18NIEe1pXeDIdozJ2Kv4hiNurb4vmwLdB

Alex009 commented 1 year ago

@hbmartin thanks for contribution!

can you show please example of generated code and kotlin source for this generated code?

hbmartin commented 1 year ago

@Alex009 I added a test file that contains expected output at https://github.com/icerockdev/moko-kswift/pull/71/files#diff-6f9bcc9e1dfe050e77b438e13f7ecab7af5abbc22e6e44ddadeb8d0b4d708a38 Still making progress on the other todo's, does this look like its on a good path?

hbmartin commented 1 year ago

@Alex009 I don't plan any further work here now, we are using this in production and it is serving well. I've attached a diagram to the description of this PR to explain the flow at a high level