I'm really loving the increased readability from not having as many typealiases in 0.6.0, so thanks for doing that! ❤️. One readability issue I still have though is storing the result of a sealed class -> swift enum in a field. eg
let state: Skie.ApplicationNew.ApplicationSummary.__Sealed = onEnum(of: getState())
(obv not needed there but if it's stored in a field on a struct or something then the type is needed).
It seems like this works on both sealed interfaces and classes and reads a fair bit nicer, as well as being easier to type/find in autocomplete:
extension ApplicationSummary {
typealias Sealed = Skie.ApplicationNew.ApplicationSummary.__Sealed
}
as you're just adding
.Sealed
(or maybe Exhaustive/Enum or something) on to the end of the main type from the shared code.
Another thing that would also help readability would be if the generated swift enums conformed to a protocol with an init that does
self = onEnum(of: sealed)
so that the conversion to the swift enum could be done in generic functions, reducing the need to call onEnum(of:) all over the codebase.