diff --git a/packages/docusaurus/src/client/exports/Link.js b/packages/docusaurus/src/client/exports/Link.js index 832b6afda6e5..749c5b1d7dc4 100644 --- a/packages/docusaurus/src/client/exports/Link.js +++ b/packages/docusaurus/src/client/exports/Link.js @@ -68,7 +68,7 @@ function Link(props) { }; }, [targetLink, IOSupported, isInternal]); - return !targetLink || !isInternal ? ( + return !targetLink || !isInternal || targetLink.startsWith('#') ? ( // eslint-disable-next-line jsx-a11y/anchor-has-content ) : (