How to force single on top of stack

My blogs directory sorts the posts by publication date. However there are some posts that I wish to stay on top of the stack and to therefore not be sorted/affected by publication date. Is there a way to go about this?

Add something like “pinned” to your front matter…

title = "foo"
date = 2023-08-08T21:33:52-07:00
pinned = true

Then in your list page…

{{ $p := where .Pages "Params.pinned" true }}
{{ $p = $p | append (complement $p .Pages) }}
{{ range $p }}
  <h2><a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a></h2>
{{ end }}