Rename Markdown links when an internal page is moved using yarn content move
#8292
Labels
accepting PR
We invite you to open a PR to resolve this issue.
idle
p2
We want to address this but may have other higher priority items.
wx
writer experience
The problem
Moving pages with
yarn content move
adds an entry in the redirect files. There is some magic ongoing in Yari to transform this redirect into the correct link when building a page.Nevertheless, Markdown links inside MDN stay the same. This leads to a few problems:
mdn/content
is made next to impossible as links are broken (this is not the only offender, but a major one)Potential solution:
When doing
yarn content move
(and notyarn content delete
), make an extra pass and edit all Markdown links inmdn/content
linking to this slug to the new one (preserving the fragment, if any).This will not solve links created by macros, but we are mostly moving around non-reference pages nowadays, and macros deal with these kinds of links so that it would cover 90% of the cases.
The text was updated successfully, but these errors were encountered: