{% comment %} if there are not many items then show the them all: 1 2 3 4 5 if there is a previous or next button then list fewer pages to cater for small screens: 1 2 3 ... 5 NEXT PREV 1 2 3 ... 5 NEXT if there are lots of items then show multiple ellipsis: 1 ... 8 9 10 ... 15 NEXT PREV 1 ... 8 9 10 ... 15 NEXT PREV 1 ... 8 9 10 ... 15 {% endcomment %} {% if pagination.paginator.num_pages > 1 %} {% endif %}