Sightly Pagination Component using Sling Model and JavaScript Use API in AEM 6.1 | Community
Skip to main content
edubey
February 24, 2016

Sightly Pagination Component using Sling Model and JavaScript Use API in AEM 6.1

  • February 24, 2016
  • 4 replies
  • 12969 views

Sightly pagination component which works together with some of the important concepts of AEM like Query Builder, Sling Model, JavaScript Use API and Sightly. In terms of functionality of this component its very similar to what we have in our AEM Community.

Read complete article here: http://adobeaemclub.com/sightly-pagination-component-using-sling-model-and-javascript-use-api-in-aem-6-1/

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

4 replies

August 10, 2018

This URL is not working. Can you please share the correct URL for reference.

arunpatidar
Community Advisor
Community Advisor
August 10, 2018
August 10, 2018

Thanks Arun. Here I see Javascript Use API has been used.. Instead can we use sling model which is recommended approach? Also, I think it is not using Ajax call. It seems to be traditional approach..

Jitendra_S_Toma
August 10, 2018

Hi Guys,

Both approaches are okay however if you are not catching ajax request then go with build response with JSON data & Html templating..handlebar or Dust js.

Having html in response is quite a heavy ajax response and mostly it is not preferred. but if you can cache ajax response then this could be useful. Another drawback is that if the response is cached then you need to find a way to keep refresh the same cache.

I hope this helps.

August 10, 2018

Hi Jitendra,

what is the recommended approach to cache the ajax response from each ajax pagination request?

Jitendra_S_Toma
August 10, 2018

Well,

First thing, if ajax request does not have too many parameters then use selectors. Secondary make sure you have TTL & Max age, cache enable for these request. There are other settings as well at the akamai & Dispatcher level for caching ajax request. Talk to dev ops if you need help.

Regards,

Jitendra

August 10, 2018

Thanks Jitender for the response.

Thanks

Rajeev