Open pjlangley opened 1 month ago
There's not a way to do pagination on the webflow.pages.getContent method.
webflow.pages.getContent
Ideally, you should be able to do something like the following so that you can cycle through the DOM nodes:
await webflow.pages.getContent('<page_id>', { offset: 100 });
Via the REST API, you can achieve it like so:
https://api.webflow.com/v2/pages/{page_id}/dom?offset=100
getContent currently only supports locale in the query params:
getContent
locale
https://github.com/webflow/js-webflow-api/blob/21c2b0fd6ef44a0bfea0a1f0099d64b6e10f86f1/src/api/resources/pages/client/Client.ts#L332-L341
Unlike webflow.pages.list, which can do pagination:
webflow.pages.list
https://github.com/webflow/js-webflow-api/blob/21c2b0fd6ef44a0bfea0a1f0099d64b6e10f86f1/src/api/resources/pages/client/Client.ts#L39-L56
Thanks @pjlangley! We'll look into fixing this
There's not a way to do pagination on the
webflow.pages.getContent
method.Ideally, you should be able to do something like the following so that you can cycle through the DOM nodes:
Via the REST API, you can achieve it like so:
getContent
currently only supportslocale
in the query params:https://github.com/webflow/js-webflow-api/blob/21c2b0fd6ef44a0bfea0a1f0099d64b6e10f86f1/src/api/resources/pages/client/Client.ts#L332-L341
Unlike
webflow.pages.list
, which can do pagination:https://github.com/webflow/js-webflow-api/blob/21c2b0fd6ef44a0bfea0a1f0099d64b6e10f86f1/src/api/resources/pages/client/Client.ts#L39-L56