()
| 28 | }); |
| 29 | |
| 30 | export function useSubscribeToAllSchemas() { |
| 31 | const subscribe = React.useMemo(() => { |
| 32 | return buildSubscribeQuery(buildAllSchemaListQuery(), { upsertKey: "id" }); |
| 33 | }, []); |
| 34 | |
| 35 | return useGlobalUpsertSubscribe({ |
| 36 | atom: allSchemas, |
| 37 | subscribe, |
| 38 | select: (row) => row.data, |
| 39 | upsertKey: (row) => row.data.id, |
| 40 | }); |
| 41 | } |
| 42 | |
| 43 | export function useAllSchemas(options?: { includeSystemSchemas?: boolean }) { |
| 44 | const includeSystemSchemas = options?.includeSystemSchemas ?? true; |
no test coverage detected