Get more than 10 records from forge customUI custom entity store

resolver.define("fetchTargetProject", async (req) => {
  try {
    const result = await storage
    return result;
  } catch (error) {
      "Error retrieving target project object by target site:",

Code in static part is below :-

useEffect(() => {
    if (targetSite !== null) {
      invoke("fetchTargetProject", { targetSite }).then(setTargetProjData);
  }, [targetSite]);

I dont know how many total records are stored in the entity. While getting the records, I am getting only 10 but want to get them all. Kindly help in how to get them all


The pattern for getting multiple pages of data is shows in the cursors section of the Custom Entities docs:

// Fetch a page of 10 results
const { nextCursor } = await storage.query().getMany();

// Fetch the next 10 results
await storage.query().cursor(nextCursor).getMany();


Can you implement the same as a form of example according to my code. I am not getting hold of the said commands of the cursor