import * as React from 'react'; import { CoreAdminContext } from '../core'; import { testDataProvider } from './testDataProvider'; import { useGetList } from './useGetList'; export default { title: 'ra-core/dataProvider/useGetList', }; const UseGetList = () => { const hookValue = useGetList('posts'); return
{JSON.stringify(hookValue, undefined, '  ')}
; }; export const NoArgs = () => { return ( ({ data: [{ id: 1, title: 'foo' } as any], total: 1, }), })} > ); }; export const WithResponseMetadata = () => { return ( ({ data: [{ id: 1, title: 'foo' } as any], total: 1, meta: { facets: { tags: [{ value: 'bar', count: 2 }] } }, }), })} > ); };