From cad3f8a37f27d7950fa1f5f4ebf5ee4a99ae7f11 Mon Sep 17 00:00:00 2001 From: Teknium <127238744+teknium1@users.noreply.github.com> Date: Sun, 19 Apr 2026 11:56:34 -0700 Subject: [PATCH] docs(site): disable highlightSearchTermsOnTargetPage to keep URLs clean (#12661) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The @easyops-cn/docusaurus-search-local option appends ?_highlight= query params to links from the search bar. Docusaurus puts the query string before the #anchor, producing URLs like /docs/foo?_highlight=bar#section which look broken when copy-pasted. Turn the option off — Ctrl+F on the landing page covers the same use case without polluting shareable links. --- website/docusaurus.config.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/website/docusaurus.config.ts b/website/docusaurus.config.ts index ad3267900..eff7750eb 100644 --- a/website/docusaurus.config.ts +++ b/website/docusaurus.config.ts @@ -37,7 +37,9 @@ const config: Config = { language: ['en'], indexBlog: false, docsRouteBasePath: '/', - highlightSearchTermsOnTargetPage: true, + // Disabled: appends ?_highlight=... to URLs (before the #anchor), + // which makes copy/pasted doc links ugly. Ctrl+F on the page is fine. + highlightSearchTermsOnTargetPage: false, }), ], ],