.Kind (page): .Type (posts) / .Layout ()
Bundle: n/a (regular page)
[ categories | projects | tags | search ]
Hugo Sandbox

This is an unofficial Hugo sandbox site to try to replicate possible bugs in hugo.

It is updated automatically after each commit to the hugo-sandbox repo. It was last updated on Jan 20, 2022 13:08 UTC.


This page was created/modified in commit bca6c8d "Add temp post" on 2018-08-07.
Markdown source of this page

Pages vs Site Pages

categories: miscellaneous


Description/Summary

Variable Current context Pages included .Site.Pages any ALL pages of the site: content, sections, taxonomies, etc. – Superset of everything! .Site.RegularPages any Only regular (content) pages – Subset of .Site.Pages .Pages List page Regular pages under that list page representing the homepage, section, taxonomy term (/tags) or taxonomy (/tags/foo) page – Subset of .Site.Pages or .Site.RegularPages, depending on context. .


Content

Variable Current context Pages included
.Site.Pages any ALL pages of the site: content, sections, taxonomies, etc. – Superset of everything!
.Site.RegularPages any Only regular (content) pages – Subset of .Site.Pages
.Pages List page Regular pages under that list page representing the homepage, section, taxonomy term (/tags) or taxonomy (/tags/foo) page – Subset of .Site.Pages or .Site.RegularPages, depending on context.
.Pages Single page empty slice

In the home context (index.html), .Pages is the same as .Site.RegularPages.

Note
.Pages is an alias to .Data.Pages. It is conventional to use that alias form.

Page (Debug)

Page VariableValue
Name "Pages vs Site Pages"
Title "Pages vs Site Pages"
ResourceType "page"
Kind "page"
Section "posts"
Draft false
Type "posts"
Layout ""
Permalink "https://hugo-sandbox.netlify.com/posts/pages-vs-site-pages/"
RelPermalink "/posts/pages-vs-site-pages/"
Data
page.Data{} (type:page.Data)
NextPagePage witting gossiping
PrevPagePost 1
NextInSectionPage witting gossiping
PrevInSectionPost 2

Page Params (Debug)

maps.Params{"author":[]string{"Kaushal Modi"}, "categories":[]string{"miscellaneous"}, "creator":"Emacs 27.0.50 (Org mode 9.1.13 + ox-hugo)", "draft":false, "iscjklanguage":false, "lastmod":time.Date(2018, time.August, 7, 9, 40, 41, 0, time.Location("")), "title":"Pages vs Site Pages"} (type:maps.Params)

File Object (Debug)

FileInfo VariableValue
UniqueID "23f86106623db2e5728a191e7f5196e1"
BaseFileName "pages-vs-site-pages"
TranslationBaseName "pages-vs-site-pages"
Lang "en"
Section "posts"
LogicalName "pages-vs-site-pages.md"
Dir "posts/"
Ext "md"
Path "posts/pages-vs-site-pages.md"

This site is generated using the ox-hugo package for Emacs/Org-mode + hugo-bare-min-theme + Hugo 0.92.0 (commit b3549403) .

[Back to Hugo Sandbox home]