Skip to main content
Version: 3.xx.xx

useLogList

Overview

If you need to list audit log events refine provides the useLogList hook for it, It uses the get method from auditLogProvider under the hood.

Usage

caution

This hook can only be used if auditLogProvider's get method is provided.

import { useLogList } from "@pankod/refine-core";

const postAuditLogResults = useLogList({
resource: "posts",
});

API

Properties

PropertyTypeDefault
resource
Required
stringAction that it reads from route
actionstring
authorRecord<string, any>
metaRecord<string, any>
metaDataMetaDataQuery
queryOptionsUseQueryOptions<TData, TError>

Type Parameters

PropertyDesriptionTypeDefault
TDataResult data of the query. Extends BaseRecordBaseRecordBaseRecord
TErrorCustom error object that extends HttpErrorHttpErrorHttpError

Return values

DescriptionType
Result of the react-query's useQueryUseQueryResult<{ data: TData; }>