Added regular pagination option

Casper comes with infinite scrolling by default. This update makes it possible to go with the default pagination style when the <html> element has a class no-infinite-scroll.
This commit is contained in:
Sodbileg Gansukh
2022-12-08 12:50:24 +08:00
parent 140632b885
commit 88ca182a58
5 changed files with 101 additions and 53 deletions

View File

@ -14,6 +14,8 @@
*/
(function (window, document) {
if (document.documentElement.classList.contains('no-infinite-scroll')) return;
// next link element
var nextElement = document.querySelector('link[rel=next]');
if (!nextElement) {