Create elegant and intuitive apps that integrate seamlessly with Apple platforms.

All subtopics

Post

Replies

Boosts

Views

Activity

SwiftUI against SwiftData is too fragile and error prone
The hardest part of SwiftUI programming is to correctly define the layers of references that you need as your app grows features. When you add Swift data to the mix, it hard to get much of anything correct. I have an application that interacts with the outside world via BLE and LocationManager. I need to preserve used BLE devices and then store their current state in a static Monitor type class structure. This monitor though, needs to have access to some SwiftData elements, and it is not clear from the documentation whether it's preferred to create multiple ModelContainer instances, when they might share a particular types management. This doesn't feel very safe, so it would then make more sense to have a ModelContainer stuck inside of some other static Monitor object that everyone would use to get the single ModelContainer that should be used. All of the context specific stacking of references in SwiftUI creates huge dependency chains, and it make the build of my application, currently to take 10s of minutes sometimes, when I have changes in flux and the compiler cannot make heads or tails out of broken references. We really need to find a way to get the compiler fixed so that as a Recursive Decent parser, it has an easier time finding a terminal state instead of crawling up and down the stack of references looking for a place that it can reach a terminal state. Not using ';' on every statement is a big part of the problem I feel...
1
0
842
Dec ’23
User Age
Hello! I need advice. According to Apple's guidelines, is it permissible to ask users during the initial app launch, through an OnBoarding screen (example in the screenshot), if they are older than 16 when the Age Rating on the App Store is set to 9+? I want to determine if the user from Europe and the UK has reached the age of consent in order to display or not display the GDPR consent form to them. Thanks!
0
1
691
Dec ’23