Releases: jblanked/EasySCADE
Releases · jblanked/EasySCADE
Release list
Push Notifications for iOS via Supabase
This uses Supabase and UserNotifications to show a notification when a new message is inserted into the messages table.
You will need to have a Supabase account and create a table called messages with a column called message.
You will also need to enable push notifications in your app via the Apple Developer Portal.
Within Supabase, you will need your Supabase URL and Supabase Key. You can find these in the API section of your Supabase project.
This code is currently for iOS only.
To use, add this in your start.swift
// top of start.swift
#if os(iOS)
import NotificationCenter
import SwiftUI
import UIKit
#endif
// in onFinishLaunching()
#if os(iOS)
@UIApplicationDelegateAdaptor(EasyAppDelegate.self) var appDelegate
#endif
Task
{
// activate did finish launching
await appDelegate.application(UIApplication.shared, didFinishLaunchingWithOptions: nil)
let supabase = Easybase(supabaseURL: "YOUR-URL",supabaseKey: "YOUR_KEY")
await supabase.subscribeToInserts(roomName: "general")
}
EasyTemplates and Swift 5.10 Support
Use Templates to Create Projects Faster
EasyTemplateLogin(self) // Login with Labels
EasyTemplateLogin(self,2) // Login without Labels
EasyTemplateLogin(self,3) // Login without Labels
EasyTemplateRegistration(self) // Registration with Labels
EasyTemplateRegistration(self,2) // Registration without Labels