|
In the HWS+ solution there was a suggestion to use @AppStorage("showingGrid") private var showingGrid = true to save the preference of the user's grid/list preference. Well it works to simply save it once, and load it... However, once you make that choice, you can never go back and change it. It seems to take away the "toggle" aspect of the button. I am targetting IOS 16, so I am not sure if I am the only one seeing this or not. Please advise for those who have used this in their version of the app. |
|
Could you share your ContentView code, so that others could look into what might be the reason of such behavior? |
|
|
|
Try to use ZStack instead of geo reader, I don't think you will need hight frame for the image. It should be placed fine in there. |
|
That worked great, I do not understand why it didnt work with GeometryReader. I still needed the frame as it then messed with the rendering of the list and in some fashion, the rendering of the grid... but this code works with Paul's @AppState
Thank you so much! such a small change! |
SAVE 50% All our books and bundles are half price for Black Friday, so you can take your Swift knowledge further without spending big! Get the Swift Power Pack to build your iOS career faster, get the Swift Platform Pack to builds apps for macOS, watchOS, and beyond, or get the Swift Plus Pack to learn advanced design patterns, testing skills, and more.
This topic has been closed due to inactivity, so you can't reply. Please create a new topic if you need to.
All interactions here are governed by our code of conduct.
Link copied to your pasteboard.