I'm working on an app where I'm building a CRM system that uses SwiftData to store invoices and contacts. The app also supports multiple saved accounts, each with its own set of invoice and contact data.
I'm wondering—how can I make sure that when users switch between accounts, the app doesn't accidentally load invoices or contacts from another account? Additionally, when a user logs in, I want to avoid resetting the storage so their data stays intact.
Thanks so much for any advice!
Best, Matthijs