aboutsummaryrefslogtreecommitdiff
path: root/haddock-api/resources/html/js-src
diff options
context:
space:
mode:
Diffstat (limited to 'haddock-api/resources/html/js-src')
-rw-r--r--haddock-api/resources/html/js-src/init.ts7
1 files changed, 6 insertions, 1 deletions
diff --git a/haddock-api/resources/html/js-src/init.ts b/haddock-api/resources/html/js-src/init.ts
index 1bfa8b3c..4a58b867 100644
--- a/haddock-api/resources/html/js-src/init.ts
+++ b/haddock-api/resources/html/js-src/init.ts
@@ -17,6 +17,11 @@ function onDomReady(callback: () => void) {
onDomReady(() => {
document.body.classList.add('js-enabled');
styleMenu.init();
- quickJump.init();
detailsHelper.init();
+ let head = document.getElementById('head');
+ let baseURL = ".";
+ if (head !== null) {
+ baseURL = head.getAttribute('data-base-url') || '.';
+ }
+ quickJump.init(baseURL);
});