UNPKG

tinacms

Version:

[![GitHub license](https://img.shields.io/github/license/tinacms/tinacms?color=blue)](https://github.com/tinacms/tinacms/blob/main/LICENSE) [![npm version](https://img.shields.io/npm/v/tinacms.svg?style=flat)](https://www.npmjs.com/package/tinacms) [![Bui

44 lines (42 loc) 1.48 kB
/** */ import type { Collection } from '@tinacms/schema-tools'; import type { TinaCMS } from '@tinacms/toolkit'; import React from 'react'; import { FilterArgs } from '../api'; import type { CollectionResponse } from '../types'; export declare const useGetCollection: (cms: TinaCMS, collectionName: string, includeDocuments: boolean, folder: { loading: boolean; fullyQualifiedName: string; }, after?: string, sortKey?: string, filterArgs?: FilterArgs) => { collection: CollectionResponse | Collection; loading: boolean; error: Error; reFetchCollection: () => void; collectionExtra: Collection<true>; }; export declare const useSearchCollection: (cms: TinaCMS, collectionName: string, includeDocuments: boolean, folder: { loading: boolean; fullyQualifiedName: string; }, after?: string, search?: string) => { collection: CollectionResponse | Collection; loading: boolean; error: Error; reFetchCollection: () => void; collectionExtra: Collection<true>; }; declare const GetCollection: ({ cms, collectionName, folder, includeDocuments, startCursor, sortKey, children, filterArgs, search, }: { cms: TinaCMS; collectionName: string; folder: { loading: boolean; fullyQualifiedName: string; }; includeDocuments?: boolean; startCursor?: string; sortKey?: string; children: any; filterArgs?: FilterArgs; search?: string; }) => React.JSX.Element; export default GetCollection;