Commit 883122e6 by 刘旋尧

搜索插件

parent 8ae84935
...@@ -18,9 +18,41 @@ ...@@ -18,9 +18,41 @@
subMaxLevel: 4, subMaxLevel: 4,
alias: { alias: {
'/.*/_sidebar.md': '/_sidebar.md' '/.*/_sidebar.md': '/_sidebar.md'
} },
search: 'auto', // 默认值
search : [
'/', // => /README.md
'/withdraw' // => /guide.md
],
// 完整配置参数
search: {
maxAge: 86400000, // 过期时间,单位毫秒,默认一天
paths: [], // or 'auto'
placeholder: 'Type to search',
// 支持本地化
placeholder: {
'/zh-cn/': '搜索',
'/': 'Type to search'
},
noData: 'No Results!',
// 支持本地化
noData: {
'/zh-cn/': '找不到结果',
'/': 'No Results'
},
// 搜索标题的最大程级, 1 - 6
depth: 6
}
} }
</script> </script>
<script src="//unpkg.com/docsify/lib/docsify.min.js"></script> <script src="//unpkg.com/docsify/lib/docsify.min.js"></script>
<script src="//unpkg.com/docsify"></script>
<script src="//unpkg.com/docsify/lib/plugins/search.js"></script>
</body> </body>
</html> </html>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment