tonyarnold,
@tonyarnold@mastodon.social avatar

The interactions between SwiftUI, SwiftData and Swift Concurrency can be confusing.

Because SwiftData Models are retrieved by Views on the MainActor, it's reasonably safe to pass them between Views, but anything around the edges will still force you to drop back to persistent identifiers and looking up the Models — it'd almost be easier to pretend that it's not safe to pass Models between Views, for consistency.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • random
  • ngwrru68w68
  • DreamBathrooms
  • thenastyranch
  • magazineikmin
  • InstantRegret
  • GTA5RPClips
  • Youngstown
  • everett
  • slotface
  • rosin
  • osvaldo12
  • mdbf
  • kavyap
  • cubers
  • megavids
  • modclub
  • normalnudes
  • tester
  • khanakhh
  • Durango
  • ethstaker
  • tacticalgear
  • Leos
  • provamag3
  • anitta
  • cisconetworking
  • JUstTest
  • lostlight
  • All magazines