diff --git a/apify-docs-theme/static/js/custom.js b/apify-docs-theme/static/js/custom.js index 38988521dc..0ad86801f2 100644 --- a/apify-docs-theme/static/js/custom.js +++ b/apify-docs-theme/static/js/custom.js @@ -74,3 +74,8 @@ document.addEventListener('scroll', () => { ticking = true; } }); + +document.addEventListener('DOMContentLoaded', () => { + // we need to wait a bit more, since the event fires too soon, and a lot of hydration is done after it + setTimeout(() => scrollSidebarItemIntoView(), 3000); +});