Hugo Geekdoc Example
GitHub Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage

Avatar

The avatar shortcode is another custom image shortcode.

Usage

Define a resource in the page front matter.

---
resources:
  - name: avatar
    src: "images/avatar.jpg"
    title: "Avatar"
---

{{< avatar name="avatar" >}}

Attributes

alt optional string
Description text for the image.
Default: none
anchor optional string
Anchor to determine the placement of the crop box.
Default: none
name required string
Name of the image resource defined in page front matter.
Default: none
size optional string
Thumbnail size. Supported values are origin|tiny|small|medium|large.
Default: none

Example

Avatar