New schema for pixels and links.
This commit is contained in:
1 parent
c60e8b3d23
commit
88639dfe83
67 files changed
+993
-208
No files matched your search
@@ -0,0 +1,15 @@
|
||||
import { useApi } from '../useApi';
|
||||
import { usePagedQuery } from '../usePagedQuery';
|
||||
import { useModified } from '../useModified';
|
||||
import { ReactQueryOptions } from '@/lib/types';
|
||||
|
||||
export function useLinksQuery({ teamId }: { teamId?: string }, options?: ReactQueryOptions<any>) {
|
||||
const { modified } = useModified('links');
|
||||
const { get } = useApi();
|
||||
|
||||
return usePagedQuery({
|
||||
queryKey: ['links', { teamId, modified }],
|
||||
queryFn: async () => get(teamId ? `/teams/${teamId}/links` : '/links'),
|
||||
...options,
|
||||
});
|
||||
}
|
||||
Reference in new issue
Block a user