mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
add instructions for managing redirects when moving docs pages around (#37113)
This commit is contained in:
parent
ddde5a5f2d
commit
5a56594f0c
@ -31,6 +31,15 @@ Syntax is:
|
|||||||
|
|
||||||
You might need to add more context for the link (containing folders and so on, `folder/example.md`) if Hugo says the relref is ambiguous.
|
You might need to add more context for the link (containing folders and so on, `folder/example.md`) if Hugo says the relref is ambiguous.
|
||||||
|
|
||||||
|
### Managing redirects
|
||||||
|
|
||||||
|
When moving content around or removing pages it's important that users following old links are properly redirected to the new location. We do this using the [aliases](https://gohugo.io/content-management/urls/#aliases) feature in Hugo.
|
||||||
|
|
||||||
|
If you are moving a page, add an `aliases` entry in the front matter referencing the old location of the page which will redirect the old url to the new location.
|
||||||
|
|
||||||
|
If you are removing a page, add an `aliases` entry in the front matter of the most-applicable page referencing the location of the page being removed.
|
||||||
|
|
||||||
|
If you are copying an existing page as the basis for a new one, be sure to remove any `aliases` entries in the front matter in your copy to avoid conflicting redirects.
|
||||||
|
|
||||||
### Edit the side menu
|
### Edit the side menu
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user