Luckily, I found a better and modern way of listening to date changes using #Combine, so I hope that fixes the problem once and for all.
Yeah, Combine is soft-deprecated, on its way out, whatever
And ObservableObject is old
Am I a fool for still reaching for them when I need to do something like this? Have a raw and debounced versions of a property, both gettable, settable, and observable as needed, both in SwiftUI and anywhere else
And the code is pretty tight I think
How would you do this, say, in the new Observable world without Combine?
I’m on Mastodon for two things.
I build things on Apple platforms. I make @tact. I read (a lot) and post (a little) about related technologies: #Swift, #SwiftUI, #Combine, #CloudKit, #CoreData, #Xcode, #concurrency, as well as product design.
I support Ukraine. I follow Ukrainians and friends of . Please donate to
until
is gone: https://u24.gov.ua or any other respected charity. My Twitter is mostly about Ukraine - https://twitter.com/jaanus
Have you ever tried using AsyncPublisher? I have. And some of its behavior has surprised me. I looked into it in-depth in my newest article, where I show how to use its behavior for your advantage, as well as how to get around its limitations. As you will see, some aspects can quite differ from observing publisher in Combine. #combine #swift #asyncpublisher #async
https://www.cleevio.com/blog/the-not-so-equivalent-code-demystifying-asyncpublisher
I’m on Mastodon for two things.
I build things on Apple platforms. I make @tact. I read (a lot) and post (a little) about related technologies: #Swift, #SwiftUI, #Combine, #CloudKit, #CoreData, #Xcode, as well as product design.
I support Ukraine. I follow Ukrainians and friends of . Please donate to
until
is gone: https://ukraineaidops.org or any other charity. My Twitter is mostly about Ukraine - https://twitter.com/jaanus