Skip to content

API: Front Matter

David Elisma edited this page Oct 21, 2022 · 1 revision

Front matter options available for pages. Not all options are mandatory.

Mandatory elements

altLangPage

Link of translated web page without the site url. Start with a /, lowercase, word separated with dashes (not spaces) and no special characters. When this option is declared the language toggle is present, otherwise it's hidden.

date

Date in ISO format of creation date of post

description

Will be used in meta name="description" and meta name="dcterm.description". Can't be empty, if not present the site description will be used. Page descriptions should be between 100 and 320 characters.

title

Used for the title tag in the head, the h1 and the meta name="dcterms.title" tag. Page titles should be between 10 and 60 characters.

Optional elements

author

Optional. meta name="dcterm.author" and meta name="dcterm.creator"

breadcrumbs

An array of a title and a link. Set by default in posts to Canada.ca > About Canada.ca > Canada.ca blog. Can be overridden in that format:

breadcrumbs:
 - title: [first page title]
   link: [first absolute url of page]
 - title: [second page title]
 	 link: [second absolute url of page]
 - ...

dateModified

Date in ISO format of last modification date of post

lang

Current language for the post. en and fr are the available options.

layout

Type of layout to use for the content. Available options:

  • core
  • default
  • fluid
  • layout-home
  • layout-servermesssage
  • layout-splashpage
  • no-container
  • without-h1

pageclass

Allow to add a class to the body tag

pageType

To use when archived page are necessary.

subject

Comma-separated list of topics to fill meta name="dcterms.subject" tag