docsify
Docsify cmd
第一次创建:
docsify init ./docs
启动(修改文件会自动刷新):
docsify serve ./docssearch problem
修改博客后,搜索不能即时生效,删的资料还能显示到搜索结果,新的资料显示不出来
?> 解决办法 删除 using Chrome: developer tools > application tab > local storage
参考 https://github.com/docsifyjs/docsify/issues/795
I finally figured my issue out, if you look into the browser's local storage (using Chrome: developer tools > application tab > local storage) you can see the content of Docsify's search index under the docsify.search.index key which helped to debug this.
I discovered my issue was a combination of two things:
The search index had been built before I had added the content I was searching for. You can clear local storage in the debugger which helps to combat this, and I suppose using a shorter maxAge property would be sufficient in production if regular updates are expected.
I was using a headline depth greater than the one specified in my depth property in my configuration, meaning the content was (correctly) not indexed. When a depth property isn't specified it looks like this defaults to 2, meaning any content under a heading like this (### Heading) would be hidden.
docsify examples
https://docs.cser.club/#/docsify/example
docsify markdown
Last updated
Was this helpful?