File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change 33
44A simple query language for SwiftData with automatic support for Swift concurrency.
55
6+ ## What is SwiftQuery?
7+
8+ The library provides an easy, modifier-like syntax that can be used to build
9+ reusable SwiftData queries. These queries can then be executed from either the
10+ ` MainActor ` or safely from a background context within any ` ModelActor ` .
11+
12+ SwiftData's ` Query ` type provides a similar ability to build queries, but unlike
13+ that type, the queries that are built using SwiftQuery are usable from anywhere—
14+ not just from within the SwiftUI environment. This lets us use saved queries from
15+ view models, reducers, background processes, etc..
16+
17+ The correct use of SwiftData models in a concurrency environment is built into the
18+ library, and enforced at compile time, making it painless to adopt best practices.
19+
20+
621## Usage
722
823``` swift
@@ -267,6 +282,10 @@ And then adding the product to any target that needs access to the library:
267282.product (name : " SwiftQuery" , package : " swift-query" ),
268283```
269284
285+ ## Authors
286+
287+ John Clayton (@johnclayton )
288+
270289## License
271290
272291swift-query is licensed under the MIT license. See [ LICENSE] ( LICENSE )
You can’t perform that action at this time.
0 commit comments