Skip to content
This repository has been archived by the owner on Dec 11, 2024. It is now read-only.

Demo App using PowerSync Swift SDK via KMMBridge + SKIE

Notifications You must be signed in to change notification settings

powersync-ja/powersync-kotlin-swift-demo

Repository files navigation

ARCHIVED: PowerSync Swift Demo App

This demo app is archived and no longer maintained. Please use the updated Swift Demo app available here.


A Todo List app demonstrating the use of the PowerSync Swift SDK together with Supabase.

The PowerSync Swift SDK is an extension of the PowerSync Kotlin Multiplatform SDK, and uses the API tool SKIE and KMMBridge to generate and publish a native Swift SDK. More details about this configuration can be found in our blog here.

The SDK reference for the PowerSync Swift SDK is available here.

Alpha Release

This SDK is currently in an alpha release and not suitable for production use, unless you have tested your use case(s) extensively. Breaking changes are still likely to occur.

Set up your Supabase and PowerSync projects

To run this demo, you need Supabase and PowerSync projects. Detailed instructions for integrating PowerSync with Supabase can be found in the integration guide.

Follow this guide to:

  1. Create and configure a Supabase project.
  2. Create a new PowerSync instance, connecting to the database of the Supabase project. See instructions here.
  3. Deploy sync rules.

Configure The App

Open the project in XCode.

Open the “_Secrets” file and insert the credentials of your Supabase and PowerSync projects (more info can be found here).

Finish XCode configuration

  1. Clear Swift caches
rm -rf ~/Library/Caches/org.swift.swiftpm
rm -rf ~/Library/org.swift.swiftpm
  1. In Xcode:
  • Reset Packages: File -> Packages -> Reset Package Caches
  • Clean Build: Product -> Clean Build Folder.
  1. Enable CasePathMacros. We are using SwiftUI Navigation for the demo which requires this.

Run project

Build the project, launch the app and sign in or register a new user.

About

Demo App using PowerSync Swift SDK via KMMBridge + SKIE

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published