Why does 𝐶𝑜𝑑𝑎𝑏𝑙𝑒 work for 𝑈𝑠𝑒𝑟𝐷𝑒𝑓𝑎𝑢𝑙𝑡𝑠 initially but break during migrations? This article explains the pitfalls when models change and presents an alternative approach using individual properties.

🔗: https://tanaschita.com/swift-user-defaults-storing-structs by Natascha Fadeeva (@tanaschita)

#Swift #UserDefaults #iOSDev

👋🏾 I’m seeking recommendations for other libraries similar to Zephyr (https://github.com/ArtSabintsev/Zephyr) that simplify syncing UserDefaults across iCloud.

#SwiftUI #UserDefaults #SwiftLang #iOSDev

GitHub - ArtSabintsev/Zephyr: Effortlessly synchronize UserDefaults over iCloud.

Effortlessly synchronize UserDefaults over iCloud. - ArtSabintsev/Zephyr

GitHub
#UserDefaults on #iOS18 in #simulator vs iOS 18 on device... Some keys seems device-specific and are not filtered .... 😕
And I have to get rid of this new key `shouldShowRSVPDataDetectors` (new in iOS 18).
#iOSDev #Swift

There are a few folks talking about the same issue:

An older Apple dev forum thread about prewarming (is this still relevant?)
https://forums.developer.apple.com/forums/thread/667959?page=2

StackOverflow post where folks blame a missing privacy manifest, but that doesn’t make sense does it?
https://stackoverflow.com/questions/77301047/ios-17-userdefaults-getting-cleared-on-relaunching-the-app

#iosdev #userdefaults

Lost data in UserDefaults | Apple Developer Forums

Has anyone else been getting reports of their iOS app’s data just… vanishing? Specifically, it sounds like UserDefaults is being reset. This doesn’t seem to be hitting a lot of my users, but the ones it hits are seeing it over and over.
#iosdev #userdefaults

The problem with lots of progress over the weekend.. is lots of write up too! So many typos... but Lines now has a button that acts just like the paste button but uses an AppGroup and UserDefaults behind the scenes instead of the Pasteboard.

https://www.whynotestflight.com/excuses/okay-but-how-about-all-the-way-up-to-the-view/

#SwiftLang, #WebExtension, #SafariWebExtension, #NativeApp, #JavaScript, #AppGroup #UserDefaults

Okay, but how about all the way up to the View?

A list of distractions

Do you use #EnviormentObjects ? I recently have been preferring #userdefaults any thoughts?

Recent #iOS development journal on data #persistency

1. Implemented everything with #UserDefaults and raw file system
2. Feeling in need of a higher level abstraction
3. #SQLite is too much for now, and I don't want to bother with schema migration on a client device
4. Core Data looks what I need, but friends warned me to avoid it
5. #GRDB seems to hold a good reputation comparing to Core Data
6. Let me try Core Data, it seems to improved a lot recently

#Apple #iOS #swift #CoreData #devjournal

#wwdc2023 on #ios and we‘re raving about getting one basic (but sluggish) button tap for „interactive“ widgets while the age-old #userdefaults key-value-store needs permission description - phew #innovation #scurve

Mac/iOS devs! PLEASE prefix your user defaults keys!

User defaults are combined in layers. So system settings like your app's accent color are inserted into your user defaults, even if you don't see them in the .plist file.

While Apple has recently switched to prefixes like ‘NS’ and ‘com.apple.’ for their defaults keys, I've seen keys in the past there that were very simple and un-prefixed. The expectation was your app would use the same prefix it used in ObjC.

#swift #userDefaults #swiftlang