-
Notifications
You must be signed in to change notification settings - Fork 5
Attachments Helper #35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 32 out of 35 changed files in this pull request and generated 2 comments.
Files not reviewed (3)
- Demo/PowerSyncExample.xcodeproj/project.pbxproj: Language not supported
- Demo/PowerSyncExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved: Language not supported
- Demo/PowerSyncExample.xcodeproj/xcshareddata/xcschemes/PowerSyncExample.xcscheme: Language not supported
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 33 out of 36 changed files in this pull request and generated 1 comment.
Files not reviewed (3)
- Demo/PowerSyncExample.xcodeproj/project.pbxproj: Language not supported
- Demo/PowerSyncExample.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved: Language not supported
- Demo/PowerSyncExample.xcodeproj/xcshareddata/xcschemes/PowerSyncExample.xcscheme: Language not supported
…-swift into attachmentshelper
Overview
Attachments helper for Swift. The logic here is a port of powersync-ja/powersync-kotlin#159.
It should technically be possible to use the Attachments logic from the core module in the Swift SDK. However, the SKIEE conversion does not handle Swift exceptions and Flows well. There are work-arounds to mitigate this, but implementing those workarounds feels like it makes the Kotlin attachment helper unnecessarily complex. Porting the code to a pure Swift implementation gives a cleaner and simpler attachment helper which does not require glue code to Kotlin types.
DEMO
Syncing attachments between iOS and MacOS devices
SwiftAttachmentsDemo.mp4
TODOS