Becoming a better engineer by looking at existing code from Apple and Swift.
It's a technique I often apply when working on my projects. Last weekend, I developed
a new major release of
SwiftUIKitView. I created a composition layer for this release based on the SwiftUI modifiers architecture.
Every modification you apply using the "set(
, to: )" modifier results in a new inheritance layer with a reference to a parent modifier. At SwiftUI redraw, the modifiers will call each other to apply each modification step. You can learn more about this by looking at the source code.
While the above explanation might be too detailed for this newsletter intro, it does explain how I got inspired by looking at SwiftUI modifiers and code structure. I do the same for API definitions and method declarations while closely examining the official Swift API Design Guidelines. Hopefully, I've inspired you to explore and look at code this way. It helps me write better code solutions, at least!
Lastly, I'm happy to announce the winners of this month's SwiftLee Giveaway, in which you were able to win one of the five Sourcery Pro licenses:
I'll get in touch with you for further details. For all others: stay tuned, as a new giveaway will follow soon!
Enjoy this week's SwiftLee Weekly!