Slug
Returns the URL slug of the given page as defined in front matter.
Syntax
PAGE.Slug
Returns
string
---
slug: sushi
title: How to make spicy tuna hand rolls
---+++
slug = 'sushi'
title = 'How to make spicy tuna hand rolls'
+++{
"slug": "sushi",
"title": "How to make spicy tuna hand rolls"
}
This page will be served from:
https://example.org/recipes/sushi
To get the slug value within a template:
{{ .Slug }} → sushiLast updated:
April 10, 2025
:
Merge commit '5be51ac3db225d5df501ed1fa1499c41d97dbf65' (283e97783)
Improve this page