can I use core data or similar on linux?

Asked on 08/03/2024

1 search

Yes, you can use Core Data or similar on Linux by leveraging Swift Data with custom data stores. Swift Data allows you to define your schema and persist your app's information using a lightweight API. By default, Swift Data uses Core Data to store information, but it also supports custom data stores, enabling you to use alternative backends like SQLite, a remote web service, or even a collection of JSON files.

For more details, you can refer to the session Create a custom data store with SwiftData which explains how to implement support for any persistence backend using the new datastore protocol.

Relevant Sessions

  1. Platforms State of the Union
  2. Create a custom data store with SwiftData
  3. What’s new in Swift