Basker Docs

Author template

Reference for the author object — bylined writers and contributors linked to posts

The author template renders an individual author's public page on the live site. Each author has their own URL and own page, making bylines clickable destinations rather than just labels.

Location

The author template lives in templates/:

└── theme
    └── templates
        ├── author.liquid           // base template
        └── author.featured.liquid  // optional named variants

Routing support

Author data can appear on post and blog templates when posts include author relationships. There is not currently a standard default route equivalent to templates/person.liquid or templates/post.liquid for author detail pages, so treat templates/author.liquid as a project convention unless your site routes to it explicitly.

The author object

PropertyTypeDescription
idstringUnique identifier
namestringThe author's display name (used in bylines)
slugstringURL-safe identifier; used to build the public URL
biobooleantrue if the rich-text bio has content
bio_htmlstringThe rich-text bio rendered as HTML
imagemediaProfile image
relativePathstringFull URL path to the author's page
postsarrayAll posts written by this author
meta.titlestringSEO title
meta.descriptionstringSEO description
meta.imagemediaSEO/OG image
createdAtstringCreation timestamp
updatedAtstringLast update timestamp

Authors may carry custom attributes if your site has defined them — check author.customAttributes.

Patterns

Author hero

<header class="author-hero">
  {% if author.image %}
    <img
      src="{{ author.image | image_url: width: 240, height: 240, fit: 'cover' }}"
      alt="{{ author.name }}"
      class="author-hero__avatar"
    >
  {% endif %}

  <h1 class="author-hero__name">{{ author.name }}</h1>

  {% if author.bio %}
    <div class="author-hero__bio rich-text">
      {{ author.bio_html }}
    </div>
  {% endif %}
</header>

List the author's posts

{% if author.posts %}
  <section class="author-posts">
    <h2>Posts by {{ author.name }}</h2>
    <ul class="author-posts__list">
      {% for post in author.posts %}
        <li class="author-posts__item">
          <a href="{{ post.relativePath }}">
            <h3>{{ post.title }}</h3>
            {% if post.description %}
              <p>{{ post.description }}</p>
            {% endif %}
            <time datetime="{{ post.publishDate }}">
              {{ post.publishDate | date: '%d %B %Y' }}
            </time>
          </a>
        </li>
      {% endfor %}
    </ul>
  </section>
{% endif %}
  • Post template — author records are linked from posts as bylines.
  • Template context — global functions and variables available alongside author.
  • Templates — the broader template-writing workflow.

On this page