I saw some posts on the forum related to this, however, none of them solves this aspect.
I got the below code that lists all pages Titles and paginates is if more than 10.
<ul>
{{ $p := where site.RegularPages "Params.hidden" "ne" true }}
{{ range (.Paginate $p).Pages }}
<li>{{ .Title }}
{{ end }}
</ul>
What I am looking for is how to make always the 1st result on the paginated page (first Title in that instance) appear in a different format. Lets say
<li><strong>{{ .Title }}</strong>
Ignore use of
as can select 1st LI from CSS and apply custom style. My example is purely theoretical and on the end, I would like to apply this to different properties like Featured Image (where on first tesult on the page, the image will not be lazy loaded, but other will be).
To be task-specific,
I want to 1 (first) element to add fetchpriority=high where to all else fetchpriority=low on 1st page, and same approach on other pages in pagination.
{{ if eq (index $p 0).Permalink .Permalink }}first post{{ else }}next{{ end }}
This will say FIRST POST to the first in the range, and NEXT for the rest.
However this will not see, that on /page/2/ the 1st result is the first on the index, as its not.