Adds full-text search capabilities to your vuepress site with a help of flexsearch library.
Many thanks to Ahmad Mostafa for the idea.
First, install plugin.
npm i vuepress-plugin-fulltext-search -D
# or
yarn add -D vuepress-plugin-fulltext-search -D
Then, enable the plugin in your docs/.vuepress/config.js
:
// docs/.vuepress/config.js
module.exports = {
// ...
plugins: ['fulltext-search'],
}
And that is it! Just compile your app and see for yourself.
Webpack alias @SearchBox
will be replaced with plugin's implementation, so it should work automatically with any
VuePress theme.