summaryrefslogtreecommitdiffstats
path: root/theme/javascript/core
diff options
context:
space:
mode:
Diffstat (limited to 'theme/javascript/core')
-rw-r--r--theme/javascript/core/search.js2
-rw-r--r--theme/javascript/core/sidebar.js1
-rw-r--r--theme/javascript/core/state.js3
3 files changed, 3 insertions, 3 deletions
diff --git a/theme/javascript/core/search.js b/theme/javascript/core/search.js
index 0aca997..a5399d9 100644
--- a/theme/javascript/core/search.js
+++ b/theme/javascript/core/search.js
@@ -11,7 +11,7 @@ define([
// Load complete index
var loadIndex = function() {
- return $.getJSON("search_index.json")
+ return $.getJSON(state.basePath+"/search_index.json")
.then(function(data) {
index = lunr.Index.load(data);
});
diff --git a/theme/javascript/core/sidebar.js b/theme/javascript/core/sidebar.js
index ab5b19a..d318676 100644
--- a/theme/javascript/core/sidebar.js
+++ b/theme/javascript/core/sidebar.js
@@ -38,7 +38,6 @@ define([
// Filter summary with a list of path
var filterSummary = function(paths) {
- console.log("filter with", paths);
$summary.find("li").each(function() {
var path = $(this).data("path");
var st = paths == null || _.contains(paths, path);
diff --git a/theme/javascript/core/state.js b/theme/javascript/core/state.js
index b219f5d..5ed11e8 100644
--- a/theme/javascript/core/state.js
+++ b/theme/javascript/core/state.js
@@ -7,6 +7,7 @@ define([
'$book': $book,
'githubId': $book.data("github"),
- 'level': $book.data("level")
+ 'level': $book.data("level"),
+ 'basePath': $book.data("basepath")
};
}); \ No newline at end of file