5 ms·
I really don't agree with most of this post but I do find the function builder[0] feature that was introduced to support SwiftUI fairly overkill. I don't fully
by K0nserv 7y ago
I really don't agree with most of this post but I do find the function builder[0] feature that was introduced to support SwiftUI fairly overkill. I don't fully understand why they didn't use a lighter abstraction based on arrays and normal return values like React does instead of adding all this "magic", maybe there's a really good reason that I am not seeing.
All the other "magic" and defaults are excellent ideas because they encode Apple's Human Interface Guidelines[1] straight into the framework which helps you create apps for the different Apple platforms that will fit in and feel at home. With a web or React Native/Flutter/Cordova/... context this might seem jarring but the whole point is that an app it shouldn't be a completely free form canvas and the frameworks should make it easy to build a best in class HIG compliant Apple app.
0: https://www.swiftbysundell.com/articles/the-swift-51-features-that-power-swiftuis-api/ https://www.swiftbysundell.com/articles/the-swift-51-feature...
1: https://developer.apple.com/design/human-interface-guidelines/ https://developer.apple.com/design/human-interface-guideline...