Function: useEprints()
useEprints(
params):UseQueryResult<OutputSchema,Error>
Defined in: web/lib/hooks/use-eprint.ts:260
Fetches a paginated list of eprints.
Parameters
params
UseEprintsParams = {}
Query parameters (limit, cursor, field)
Returns
UseQueryResult<OutputSchema, Error>
Query result with eprint list
Remarks
Uses placeholder data to show previous results while fetching new ones, providing a smoother pagination experience.
Example
const { data, isLoading, error } = useEprints({
field: 'computer-science',
limit: 20,
});
return (
<EprintList
eprints={data?.eprints ?? []}
isLoading={isLoading}
/>
);
Throws
When the eprints API request fails