浏览代码

rename search_data to search_index

Rodja Trappe 1 年之前
父节点
当前提交
f8d78f3302
共有 3 个文件被更改,包括 2 次插入2 次删除
  1. 1 1
      search.vue
  2. 1 1
      website/build_search_index.py
  3. 0 0
      website/static/search_index.json

+ 1 - 1
search.vue

@@ -34,7 +34,7 @@ export default {
   },
 
   async created() {
-    let response = await fetch("/static/search_data.json");
+    let response = await fetch("/static/search_index.json");
     if (!response.ok) {
       throw new Error(`HTTP error! status: ${response.status}`);
     }

+ 1 - 1
website/build_search_data.py → website/build_search_index.py

@@ -39,5 +39,5 @@ for file in Path('./more_documentation').glob('*.py'):
         tree = ast.parse(source.read())
         DemoVisitor('_'.join(file.stem.split('_')[:-1])).visit(tree)
 
-with open('static/search_data.json', 'w') as f:
+with open('static/search_index.json', 'w') as f:
     json.dump(documents, f, indent=2)

+ 0 - 0
website/static/search_data.json → website/static/search_index.json