]> git.maquefel.me Git - brevno-suite/hugo/commit
Make Page.Aliases more useful in multidimensional setups (note)
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Fri, 23 Jan 2026 17:52:35 +0000 (18:52 +0100)
committerGitHub <noreply@github.com>
Fri, 23 Jan 2026 17:52:35 +0000 (18:52 +0100)
commitee91c707eed62dd008c1d99fed1b65f6cd2a3974
tree27bf3a0139c563778cf8cdd67b65bec803ffc3c0
parent11f7f39913d56291f0e049f674378da06cfd4e70
Make Page.Aliases more useful in multidimensional setups (note)

There are 2 fundamental changes related to alias handling in this PR:

1. the `Page.Aliases`` method returns a ready-to-use list of aliases, not the raw input data. This means that it's prefixed with correct dimension values (e.g. language code) and output format paths, and ready to use in e.g. Netlify's _redirects file.
2. We only render aliases for output formats that is both defined as `IsHTML` and `Permalinkable`.

See #14402
common/paths/path.go
common/paths/path_test.go
hugolib/alias_test.go
hugolib/disableKinds_test.go
hugolib/page__meta.go
hugolib/page__output.go
hugolib/site.go
hugolib/site_render.go
resources/page/page.go