Featured Image
The theme presents the featured image at the top of your page and in preview cards. It’s also prepared for references in search engines and social networks.
Syntax
The featured image needs to be provided either as a page resource with the name featured or as a data file (YAML, TOML, or JSON) with this base name.
In case you want to use an image already registered in the page resources under a different name, you can mark it with the parameter featured: image-name
. If no specific featured image is given for a page, the theme will search related pages for a fallback.
All the parameters available for enhancing images are available except the ones for the width, which depends on the current page layout.
- News, Blog, Docs
- The small width is the default and we can only use tiny as an alternative.
- Articles [TODO]
- The default width for articles is large and we can only use the alternatives text or xlarge.
Size of the image
The necessary width depends on the layout but we should consider the use of a featured image for previews in another context. The preferred width of social networks may be significantly higher.
Menu icon as image
When there already is a menu icon in the frontmatter of a documentation page, we can simply reuse it by setting the parameter featured: icon
.