Ok. It’s clear. Thanks. Could you please do similar experiment with UIViewControllerRepresentable? Some time ago I noticed that it behaves differently, meaning that it is being rendered when it is evaluated. Can you please confirm or deny it?
If the textfield is multilined, And asyncimage url don't depend on textfield(name), Will image need re-render when input to textfield such that it switched from 1 line to 2 lines expanding the total height of UI?
When the data passed into AsyncImage is different from last time, it's body is re-evaulated the same way as ContentView's body is re-evaluated when @State changes. i.e. body is called when a let or a state var is different from last time. I wouldn't call this re-rendering because that term is better suited to after SwiftUI diffs the body evaulations and uses the result to create/update UIView objects which then CoreGraphics renders to screen, e.g. in the drawRect method.
know where to start a new soft and I didn't know how to switch from soft to . You are the best THANK YOU FOR NOT
Really helpful video to understand the rendering process of Views based on State changes
Great use of Instruments to really nail down the point.
Ok. It’s clear. Thanks. Could you please do similar experiment with UIViewControllerRepresentable? Some time ago I noticed that it behaves differently, meaning that it is being rendered when it is evaluated. Can you please confirm or deny it?
..similar to jetpack compose recomposition, it only recompose the component that state changes
Superb 👌
Need more of instruments 🔥🔥
Thanks for good tutorial. I am getting problem, which says: ImmersiveScene: @self changed. How to investigate why did it happen?
If the textfield is multilined,
And asyncimage url don't depend on textfield(name),
Will image need re-render when input to textfield such that it switched from 1 line to 2 lines expanding the total height of UI?
When the data passed into AsyncImage is different from last time, it's body is re-evaulated the same way as ContentView's body is re-evaluated when @State changes. i.e. body is called when a let or a state var is different from last time. I wouldn't call this re-rendering because that term is better suited to after SwiftUI diffs the body evaulations and uses the result to create/update UIView objects which then CoreGraphics renders to screen, e.g. in the drawRect method.
Yes. That is what I explained in the video.