diff --git a/packages/docusaurus/src/client/exports/Link.tsx b/packages/docusaurus/src/client/exports/Link.tsx index ac56101ae79c..92786572baf1 100644 --- a/packages/docusaurus/src/client/exports/Link.tsx +++ b/packages/docusaurus/src/client/exports/Link.tsx @@ -81,14 +81,10 @@ function Link( ? maybeAddBaseUrl(targetLinkWithoutPathnameProtocol) : undefined; - // TODO not temp hack + // TODO temporary hack if (router === 'hash' && targetLink?.startsWith('./')) { targetLink = targetLink?.slice(1); } - console.log('link', { - before: targetLinkWithoutPathnameProtocol, - after: targetLink, - }); if (targetLink && isInternal) { targetLink = applyTrailingSlash(targetLink, {trailingSlash, baseUrl}); @@ -157,8 +153,7 @@ function Link( const hasInternalTarget = !props.target || props.target === '_self'; // Should we use a regular tag instead of React-Router Link component? - const isRegularHtmlLink = - !targetLink || !isInternal || !hasInternalTarget || isAnchorLink; + const isRegularHtmlLink = !targetLink || !isInternal || !hasInternalTarget; if (!noBrokenLinkCheck && (isAnchorLink || !isRegularHtmlLink)) { brokenLinks.collectLink(targetLink!);