Examples for the Lighter SQLite environment, SwiftUI and server side.
Note: The examples require Swift 5.7 / Xcode 14b for proper plugin support.
When embedding a package using Enlighter (like NorthwindSQLite.swift), a local package seems to be required w/ the Xcode 14 beta (3...5). Otherwise the Swift package plugins do not seem to run. In the example project this is the "AppLogic" package. If Xcode gets stuck or doesn't run the plugin, a package update sometimes help.
The Northwind database is a common database example that has been ported to SQLite. Lighter provides a Swift version of that in the NorthwindSQLite.swift repository.
Note: The particular SQLite version of the Northwind database is quite lacking. For example booleans are stored as TEXTs, many columns are inappropriately marked as
That actually makes it a good example on how to deal with such databases in Lighter.
The Swift Northwind API: Documentation.
This example pulls in a lot of bigger dependencies. A real Lighter project can actually work w/ no external dependencies at all.
|Last commit: 8 weeks ago|
Code adjusted for Swift 5.9.