fix(site): strip version build info from docs link URLs (#14601)

This commit is contained in:
Justin Fowler
2024-09-10 10:15:23 -06:00
committed by GitHub
parent 0787c42d32
commit 85cc695dc6
+1 -1
View File
@@ -9,7 +9,7 @@ function defaultDocsUrl(): string {
}
// Strip the postfix version info that's not part of the link.
const i = version?.indexOf("-") ?? -1;
const i = version?.match(/[+-]/)?.index ?? -1;
if (i >= 0) {
version = version.slice(0, i);
}