Skip to content

Commit 28093ab

Browse files
committed
Further explain complex anchoring scenarios in the docs.
1 parent a9075eb commit 28093ab

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

docs/contribute/redirects.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,9 +138,10 @@ redirects:
138138

139139
```yaml
140140
redirects:
141+
# In this first scenario, the default redirection target remains the same page, with anchors being preserved.
142+
# Omitting the ``anchors`` tag or explicitly setting it as empty are both supported.
141143
'testing/redirects/8th-page.md':
142144
to: 'testing/redirects/8th-page.md'
143-
anchors: {}
144145
many:
145146
- to: 'testing/redirects/second-page.md'
146147
anchors:
@@ -149,6 +150,7 @@ redirects:
149150
anchors:
150151
'item-b':
151152
153+
# In this scenario, the default redirection target is a different page, and anchors are dropped.
152154
'testing/redirects/deleted-page.md':
153155
to: 'testing/redirects/5th-page.md'
154156
anchors: '!'

0 commit comments

Comments
 (0)