()
| 18 | }) |
| 19 | |
| 20 | function QueryPage() { |
| 21 | // Get data using live queries with Query collections |
| 22 | const todos = useLiveQuery((q) => |
| 23 | q |
| 24 | .from({ todo: queryTodoCollection }) |
| 25 | .orderBy(({ todo }) => todo.created_at, `asc`), |
| 26 | ) |
| 27 | |
| 28 | const configData = useLiveQuery((q) => |
| 29 | q.from({ config: queryConfigCollection }), |
| 30 | ) |
| 31 | |
| 32 | return ( |
| 33 | <Suspense fallback="Loading..."> |
| 34 | <TodoApp |
| 35 | todos={todos()} |
| 36 | configData={configData()} |
| 37 | todoCollection={queryTodoCollection} |
| 38 | configCollection={queryConfigCollection} |
| 39 | title="todos (query)" |
| 40 | /> |
| 41 | </Suspense> |
| 42 | ) |
| 43 | } |
nothing calls this directly
no test coverage detected