LiveQuery stops and does not restart in the background

The Swift SDK is designed for SwiftUI and MVVM out-of-the-box. A LiveQuery Subscription is already a View Model as discussed in the documentation, so using subscribeCallback in the manner you are using it is the long way:

Cloud Functions and every Query can be used directly as a View Model without any additional code as well. The Playgrounds shows how to use a LiveQuery as a View Model directly:

I discuss and show examples on how to make sophisticated View Models leveraging subscriptions and standard queries by conforming and subclassing to what the Swift SDK provides: