🎨 Optimised infinite scroll (#503)

no issue
- removed jQuery usage
- use the `<link rel="next">` tag provided by Ghost to determine the next page to fetch
This commit is contained in:
汪磊
2018-12-05 20:38:11 +08:00
committed by Kevin Ansfield
parent f695d69aeb
commit 3c2347c7f9
4 changed files with 74 additions and 103 deletions

View File

@ -76,12 +76,6 @@
<script type="text/javascript" src="{{asset "built/jquery.fitvids.js"}}"></script>
{{#if pagination.pages}}
<script>
// maxPages is a global variable that is needed to determine
// if we need to load more pages for the infinitescroll, or if
// we reached the last page already.
var maxPages = parseInt('{{pagination.pages}}');
</script>
<script src="{{asset "built/infinitescroll.js"}}"></script>
{{/if}}