Post

Replies

Boosts

Views

Activity

Comment on How does listSectionSpacing works in SwiftUI?
If you're finding additional weirdness where the numbers don't add up, try .environment(\.defaultMinListRowHeight, 0) - sometimes section space or headers/footers have a minimum size that won't be overridden by other modifiers such as listSectionSpacing. IMO Apple has over-engineered all of this. A concept like bottom padding would have been so much simpler.
Topic: UI Frameworks SubTopic: SwiftUI
Nov ’24
Comment on How does listSectionSpacing works in SwiftUI?
Haha I came here to tell you this and then as the story unfolded, you arrived at the same conclusion :) From the experiments I've run and from what I've seen in other forums, it takes half of the spacing value from each section. So if the spacing is the same for each section, then it will return the true value. However, if the values are different, it will be as you've shown above. This is also true if a section butts up against a non-section, as it's (value/2) + (0/2).
Topic: UI Frameworks SubTopic: SwiftUI
Nov ’24