Core Data Best Practices
Core Data Best Practices
Core Data Manages Persistence
- Getting view controllers what they need when using
- Posts that have been inserted/ deleted
- More complecated → Chaos → Bad UX
- Query generations helps you
- Isolate contexts from completing work
- Provide a consistent, durable view of the database
- Requires WAL journal mode
- New in iOS 11 and macOS 10.13
- Persisted record of each transaction
- Old — nil or NSKeyedUnarchiveFromDataTrasnformerName
- New — NSSecureUnarchiveFromDataTransformerName
- Custom classes need a custom transformer
CoreData Debug Log