X Enterprises
nuxt-x-affiliate

Post Navigation

Previous / next links at the foot of an article or review.

Post Navigation

Previous / next links at the foot of an article or review.

Accepts either a slug (joined onto basePath) or a full path, so it works with a hand-rolled content list or with Nuxt Content's path field.

Components

<XAFPostNavigation />

<XAFPostNavigation
  :previous="{ title: 'How we test grinders', slug: 'how-we-test-grinders' }"
  :next="{ title: 'Best pour-over kettles of 2026', slug: 'best-pour-over-kettles' }"
  base-path="/reviews"
/>

Props

PropTypeDefaultDescription
previous{ title, slug?, path? }—The older post. Omit at the start of a series
next{ title, slug?, path? }—The newer post. Omit at the end
basePathstring'/blog'Prefix joined to slug when a post has no path
previousLabelstring'Previous'Label above the previous title
nextLabelstring'Next'Label above the next title

Tips

  • path wins over slug when both are present.
  • Trailing slashes on basePath and leading slashes on slug are both tolerated — you won't get /blog//my-post.
  • The links carry rel="prev" / rel="next". With only one neighbour, an empty column keeps next right-aligned.

AI Context

component: XAFPostNavigation
package: "@xenterprises/nuxt-x-affiliate"
use-when: Previous/next links at the foot of an article or review
Copyright © 2026