package kinds
import "github.com/gohugoio/hugo/resources/kinds"
Index ¶
- Constants
- Variables
- func GetKindAny(s string) string
- func GetKindMain(s string) string
- func IsBranch(kind string) bool
- func IsDeprecatedAndReplacedWith(s string) string
Constants ¶
const ( KindPage = "page" KindHome = "home" KindSection = "section" // Note that before Hugo 0.73 these were confusingly named // taxonomy (now: term) // taxonomyTerm (now: taxonomy) KindTaxonomy = "taxonomy" KindTerm = "term" // The following are (currently) temporary nodes, // i.e. nodes we create just to render in isolation. KindRSS = "rss" KindSitemap = "sitemap" KindSitemapIndex = "sitemapindex" KindRobotsTXT = "robotstxt" KindStatus404 = "404" )
Variables ¶
var ( // This is all the kinds we can expect to find in .Site.Pages. AllKindsInPages []string // This is all the kinds, including the temporary ones. AllKinds []string )
Functions ¶
func GetKindAny ¶
GetKindAny gets the page kind given a string, empty if not found.
func GetKindMain ¶
GetKindMain gets the page kind given a string, empty if not found. Note that this will not return any temporary kinds (e.g. robotstxt).
func IsBranch ¶
IsBranch returns whether the given kind is a branch node.
func IsDeprecatedAndReplacedWith ¶
IsDeprecatedAndReplacedWith returns the new kind if the given kind is deprecated.
Source Files ¶
- Version
- v0.144.2 (latest)
- Published
- Feb 19, 2025
- Platform
- linux/amd64
- Imports
- 2 packages
- Last checked
- 13 hours ago –
Tools for package owners.