Realm + Codable. Part 2.
There are two ways of pre-populating a Realm database:
- Use Realm browser to enter all the data manually or import it there from .xls or csv.
- Parse data from a JSON source once your app is launched.
Reflection is something that you normally don’t use with statically typed languages like Swift. However, reflection support has been present since Swift 2, offering a read-only access to the properties of an instance, and, although still very limited (you can’t access computed properties and…