summaryrefslogtreecommitdiffstats
path: root/assets
diff options
context:
space:
mode:
authorSerghei Iakovlev <egrep@protonmail.ch>2022-07-05 03:11:36 +0200
committerSerghei Iakovlev <egrep@protonmail.ch>2022-07-05 03:11:36 +0200
commit16fee44dbd2efe2fc968a71b4a21c72d36f7ec1e (patch)
tree2f315c4fc248fb3886cd848f6ec9c28779e28c96 /assets
parentef8c42c2e959edc8dba65c8c20acf41088f14b79 (diff)
downloadgohugo-theme-ed-16fee44dbd2efe2fc968a71b4a21c72d36f7ec1e.tar.gz
Add support of indexing multi-language content
Diffstat (limited to 'assets')
-rw-r--r--assets/js/search.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/assets/js/search.js b/assets/js/search.js
index 262a92f..489e8fd 100644
--- a/assets/js/search.js
+++ b/assets/js/search.js
@@ -40,6 +40,9 @@ async function initSearchIndex() {
// Create the lunr index for the search
searchIndex = lunr(function () { // eslint-disable-line no-undef
+ // TODO: Add support fpr more languages
+ this.use(lunr.multiLanguage('en', 'ru'));
+
this.field('title');
this.field('categories');
this.field('tags');