2 ms·
I suspect many of the cases where things are not documented as to what they'll produce or how the layout will look are intentional, as SwiftUI seems to have the
by saagarjha 6y ago
I suspect many of the cases where things are not documented as to what they'll produce or how the layout will look are intentional, as SwiftUI seems to have the (somewhat idealistic) goal of "looking right" and not only does it have to infer intent from what you've written it also needs to be flexible enough to adapt to Apple's design roadmap for the future. So there's no documentation, not only because there are so many special case quirks they've added to support layouts that are considered "best practice design" in UIKit that nobody can really keep up or discover, but also because if they tie something down too much they won't be able to change it to a new design or paradigm. I suspect that they really want for 2022 to roll around and be able to come out on the stage at a WWDC and say that all apps using SwiftUI already get support on their new AR headset, and all standard controls have been mapped to analogues on that platform. If you document NavigationView as being a vibrant view on the top with a large title and a scroll view under it, you can't do this.
Many of the bugs probably have more to do with the unshippability of macOS at the moment.