2 ms·
The first step is usually to figure out what is actually taking all the time, Instruments is good at this. What did it say? Was it your code, or AttributeGraph
by saagarjha 4y ago
The first step is usually to figure out what is actually taking all the time, Instruments is good at this. What did it say? Was it your code, or AttributeGraph stuff? Or maybe layout code in UIKit/AppKit? Once you find that you will probably want to isolate which part of your UI is actually triggering this. Ideally identifying if it's a "I got called once and SwiftUI freaked out" or "SwiftUI keeps calling me for changes and I don't have any changes, but this is still bad for performance".