Rewrite

Layout to rewrite page to another page.

Donate

Become a backer or sponsor to support our work.

Sponsors

Parameters

layout

NameContextTypeRequiredDefaultSinceExample
layout-string---

MUST be rewrite.

rewrite.path

NameContextTypeRequiredDefaultSinceExample
rewrite.path-string---

The path of page.

rewrite.template

NameContextTypeRequiredDefaultSinceExample
rewrite.template-string-single--

The render template.

Example

Let’s said there is a /docs/overview detailed page, and rewrite the homepage to that page, you’ll need to configure parameters on front matter as follows.

content/_index.md
1---
2layout: rewrite
3rewrite:
4  path: /docs/overview
5---