mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-10 23:57:22 +02:00
Fix markdown html link replacement
This commit is contained in:
parent
aba6e93c5d
commit
d2eaf04ec7
1 changed files with 5 additions and 2 deletions
|
@ -202,11 +202,14 @@ function execute(port) {
|
|||
link = link.replace("/en/", "/" + language + "/");
|
||||
link = link.replace(
|
||||
"/VERSION/",
|
||||
metadata.version && (metadata.version !== latestVersion)
|
||||
metadata.version && metadata.version !== latestVersion
|
||||
? "/" + metadata.version + "/"
|
||||
: "/"
|
||||
);
|
||||
rawContent = rawContent.replace(new RegExp(key, "g"), link);
|
||||
rawContent = rawContent.replace(
|
||||
new RegExp("\\]\\(" + key, "g"),
|
||||
"](" + link
|
||||
);
|
||||
});
|
||||
|
||||
rawContent = rawContent.replace(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue