Closed owenzhao closed 2 years ago
I doubt this is an issue with Defaults
as the observation code is the same for macOS and iOS. However, submitting a failing test would be very helpful.
I created a new project but I couldn't reproduce this issue. So I now close this issue.
I used iCloud Key-Value sync together with Defaults.
And I used
Defaults.observe
to updated UI.Above code worked on macOS. However, on iOS the UI would never be triggered when
defaults.set(value, forKey: key)
called. I had to manually callDefaults
to trigger.As
Defaults
didn't allow Any. In the way, I had to specify each key in switch-case. Any idea?