The page-type front matter key

The page-type front matter key describes the type of an MDN page. This allows MDN content tools to better automate content checking and sidebar organization.

Like any other front matter key, the page-type key is specified in the YAML at the start of "index.md":

---
title: Geolocation.getCurrentPosition()
slug: Web/API/Geolocation/getCurrentPosition
page-type: web-api-instance-method
browser-compat: api.Geolocation.getCurrentPosition
---

Each main area of the site — JavaScript, CSS, and so on — has a set of domain-specific page-type values, and there is also a set of generic values that can appear in any area of the site.

This project is a work in progress: so far we have only defined page-type values for the CSS pages and the Web API pages.

Generic page types

These page types are not specific to a particular MDN technology area:

  • guide: a generic guide page with no specific structure. See Conceptual page.
  • landing-page: a page that acts primarily as a navigation aid, listing links to other pages. See Landing page.

Web API page types

This section lists page-type values for pages under Web/API. Every page in that part of the tree must have a page-type, and its value must be one of those listed below or one of the generic page type values.

CSS page types

This section lists page-type values for pages under Web/CSS. Every page in that part of the tree must have a page-type, and its value must be one of those listed below or one of the generic page type values.