[#]SwiftUI onPreferenceChange now requires a Sendable non-async closure in Xcode 16.2.
Does this mean we aren't supposed to be manipulating view state when a Preference value changes? Kicking off a Task satisfies the compiler, but seems like a bad idea.
How exactly are we supposed to be using onPreferenceChange now? Are there any other ways of passing values up the hierarchy that still work? Why aren't breaking changes like this explained in the release notes?
=> More informations about this toot | View the thread | More toots from dale_price@mastodon.online
=> View swiftui tag This content has been proxied by September (3851b).Proxy Information
text/gemini