I have a shared view in my app that can be called in different places. The root of this view is a scroll view, but sometimes it ignores the top safe area and it collapses under the navigation bar.
Here two screenshots that shows better the problem:
As you can see in the second screenshot the scrollview extends for all the screen collapsing under the navigation. How can I avoid this?
Solved using:
.navigationViewStyle(StackNavigationViewStyle())
in all the NavigationView