I found some answers but I have more questions now. I found that I have to use function “findPage()” to get pagination data.
But when I use “start” and “limit” parameters, they are not taken into account. All my entites are returned.
const { results: studyMotsResponse, pagination: pageResult } =
await strapi.entityService.findPage("api::study-mot.study-mot", {
filters: {
...filters,
user: userId,
},
start,
limit,
});
console.log(pageResult);
return toEntityResponseCollection(studyMotsResponse);
// start:0 limit:5
// log => { page: 1, pageSize: 10, pageCount: 1, total: 10 }
Does I have to use other parameters ?
Another question how can I return my pagination meta data from my resolver ?