Toot

Written by Duncan Babbage on 2024-09-29 at 23:46

Interesting finding on a #SwiftUI performance issue. Made a sample app to test. With a 6,500 item collection, if I have a List containing a ForEach and call a RowView() within that ForEach that defines the row contents, the body on RowView is called 6,500 times indicating 6,500 rows are rendered.

If the identical contents of that RowView are placed directly inside the ForEach, only 37 rows are initially rendered, when 17 fit on the screen.

I’m unclear why. Would love any insights. #iOSDev

=> More informations about this toot | View the thread | More toots from babbage@iosdev.space

Mentions

Tags

=> View swiftui tag | View iosdev tag

Proxy Information
Original URL
gemini://mastogem.picasoft.net/toot/113223506587777438
Status Code
Success (20)
Meta
text/gemini
Capsule Response Time
225.637799 milliseconds
Gemini-to-HTML Time
0.626002 milliseconds

This content has been proxied by September (3851b).