{"id":13566877,"url":"https://github.com/easyops-cn/docusaurus-search-local","last_synced_at":"2026-02-13T06:42:51.225Z","repository":{"id":37325031,"uuid":"305047199","full_name":"easyops-cn/docusaurus-search-local","owner":"easyops-cn","description":"Offline/local search for Docusaurus v2/v3","archived":false,"fork":false,"pushed_at":"2026-01-29T08:31:22.000Z","size":7034,"stargazers_count":873,"open_issues_count":90,"forks_count":111,"subscribers_count":9,"default_branch":"master","last_synced_at":"2026-01-31T16:18:54.828Z","etag":null,"topics":["docusaurus","docusaurus-v3","docusaurus2","search"],"latest_commit_sha":null,"homepage":"https://easyops-cn.github.io/docusaurus-search-local/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/easyops-cn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-10-18T07:32:46.000Z","updated_at":"2026-01-29T08:28:34.000Z","dependencies_parsed_at":"2024-05-23T08:48:40.301Z","dependency_job_id":"6df6e51b-77f3-44c3-b049-cd5d12865d02","html_url":"https://github.com/easyops-cn/docusaurus-search-local","commit_stats":{"total_commits":370,"total_committers":27,"mean_commits":"13.703703703703704","dds":0.4621621621621622,"last_synced_commit":"3f28255e33fd2a1d0635f63b200d5baf4d733dff"},"previous_names":[],"tags_count":121,"template":false,"template_full_name":null,"purl":"pkg:github/easyops-cn/docusaurus-search-local","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easyops-cn%2Fdocusaurus-search-local","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easyops-cn%2Fdocusaurus-search-local/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easyops-cn%2Fdocusaurus-search-local/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easyops-cn%2Fdocusaurus-search-local/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/easyops-cn","download_url":"https://codeload.github.com/easyops-cn/docusaurus-search-local/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/easyops-cn%2Fdocusaurus-search-local/sbom","scorecard":{"id":364265,"data":{"date":"2025-08-11","repo":{"name":"github.com/easyops-cn/docusaurus-search-local","commit":"c326329a9106bd629127eb63bc05856640d75bec"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":4.4,"checks":[{"name":"Code-Review","score":6,"reason":"Found 8/12 approved changesets -- score normalized to 6","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":10,"reason":"25 commit(s) and 6 issue activity found in the last 90 days -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.yml:1","Warn: no topLevel permission defined: .github/workflows/gh-pages.yml:1","Warn: no topLevel permission defined: .github/workflows/release-please.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: third-party GitHubAction not pinned by hash: .github/workflows/ci.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:26: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:29: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:37: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/ci.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/ci.yml:50: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/ci.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/gh-pages.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/gh-pages.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/gh-pages.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/gh-pages.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/gh-pages.yml:32: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/gh-pages.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/gh-pages.yml:45: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/gh-pages.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/release-please.yml:20: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/release-please.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release-please.yml:41: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/release-please.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release-please.yml:44: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/release-please.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release-please.yml:52: update your workflow using https://app.stepsecurity.io/secureworkflow/easyops-cn/docusaurus-search-local/release-please.yml/master?enable=pin","Info:   0 out of   9 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   4 third-party GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 28 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"47 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-qwcr-r2fm-qrc7","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-pxg6-pf52-xh8x","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-f7f6-9jq7-3rqj","Warn: Project is vulnerable to: GHSA-rv95-896h-c2vc","Warn: Project is vulnerable to: GHSA-qw6h-vgh9-j6wx","Warn: Project is vulnerable to: GHSA-jchw-25xp-jwwc","Warn: Project is vulnerable to: GHSA-cxjh-pqwp-8mfp","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-rc47-6667-2j5j","Warn: Project is vulnerable to: GHSA-c7qv-q95q-8v27","Warn: Project is vulnerable to: GHSA-4www-5p9h-95mh","Warn: Project is vulnerable to: GHSA-9gqv-wp59-fq42","Warn: Project is vulnerable to: GHSA-78xj-cgh5-2h22","Warn: Project is vulnerable to: GHSA-2p57-rm9w-gvfp","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-76p3-8jx3-jpfq","Warn: Project is vulnerable to: GHSA-3rfm-jhwj-7488","Warn: Project is vulnerable to: GHSA-hhq3-ff78-jv3g","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55","Warn: Project is vulnerable to: GHSA-76c9-3jph-rj3q","Warn: Project is vulnerable to: GHSA-9wv6-86v2-598j","Warn: Project is vulnerable to: GHSA-rhx6-c78j-4q9w","Warn: Project is vulnerable to: GHSA-x7hr-w5r2-h6wg","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg","Warn: Project is vulnerable to: GHSA-76p7-773f-r4q5","Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p","Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36","Warn: Project is vulnerable to: GHSA-4wf5-vphf-c2xc","Warn: Project is vulnerable to: GHSA-jgrx-mgxx-jf9v","Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3","Warn: Project is vulnerable to: GHSA-c76h-2ccp-4975","Warn: Project is vulnerable to: GHSA-cxrh-j4jr-qwg3","Warn: Project is vulnerable to: GHSA-4vvj-4cpr-p986","Warn: Project is vulnerable to: GHSA-4v9v-hfq4-rm2v","Warn: Project is vulnerable to: GHSA-9jgg-88mc-972h","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q","Warn: Project is vulnerable to: GHSA-c4w7-xm78-47vh","Warn: Project is vulnerable to: GHSA-f9xv-q969-pqx4"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-18T11:30:04.613Z","repository_id":37325031,"created_at":"2025-08-18T11:30:04.613Z","updated_at":"2025-08-18T11:30:04.613Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29122602,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-05T10:47:47.471Z","status":"ssl_error","status_checked_at":"2026-02-05T10:45:08.119Z","response_time":65,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docusaurus","docusaurus-v3","docusaurus2","search"],"created_at":"2024-08-01T13:02:18.695Z","updated_at":"2026-02-13T06:42:51.215Z","avatar_url":"https://github.com/easyops-cn.png","language":"TypeScript","funding_links":[],"categories":["TypeScript","others"],"sub_categories":[],"readme":"# @easyops-cn/docusaurus-search-local\n\n[![Npm Version](https://img.shields.io/npm/v/@easyops-cn/docusaurus-search-local)](https://www.npmjs.com/package/@easyops-cn/docusaurus-search-local)\n[![CI Status](https://github.com/easyops-cn/docusaurus-search-local/workflows/gh-pages/badge.svg?event=push\u0026branch=master)](https://github.com/easyops-cn/docusaurus-search-local/actions?query=workflow%3Agh-pages)\n[![Coverage Status](https://coveralls.io/repos/github/easyops-cn/docusaurus-search-local/badge.svg?branch=master)](https://coveralls.io/github/easyops-cn/docusaurus-search-local?branch=master)\n\nAn offline/local search plugin/theme for [Docusaurus v2/v3](https://docusaurus.io/), which supports multiple languages, especially optimized for language of zh.\n\n\u003e Originally forked from [cmfcmf/docusaurus-search-local](https://github.com/cmfcmf/docusaurus-search-local).\n\u003e\n\u003e Then later fully rewritten with TypeScript 💪, styles polished 💅, language of Chinese supported 🇨🇳, and tests covered ✅.\n\n- [Live Demo](#live-demo)\n- [Screen Shots](#screen-shots)\n- [Installation](#installation)\n- [Usage](#usage)\n- [Theme Options](#theme-options)\n- [Custom Styles](#custom-styles)\n- [Trouble Shooting](#trouble-shooting)\n- [Further Reading](#further-reading)\n- [Contributing](#contributing)\n\n## Live Demo\n\nhttps://easyops-cn.github.io/docusaurus-search-local/\n\n## Screen Shots\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"screen-shots/screen-shot-en.png\" alt=\"Screen Shot EN\" width=\"591\" /\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"screen-shots/screen-shot-zh.png\" alt=\"Screen Shot ZH\" width=\"602\" /\u003e\n\u003c/p\u003e\n\n## ✨ Ask AI Support\n\nThis plugin now supports **Ask AI** integration! Enable AI-powered assistance directly in your documentation site to help users get instant, context-aware answers.\n\nNOTE: Ask AI feature requires an external AI service. Please refer to the [Open Ask AI Server](https://github.com/easyops-cn/open-ask-ai-server), which is a serverless solution, and can be used **for free** using Vercel Hobby Plan!\n\n### Installing Ask AI\n\nThe Ask AI feature is **opt-in**. To enable it, you need to install the `open-ask-ai` package separately:\n\n```shell\nnpm install --save open-ask-ai\n# or\nyarn add open-ask-ai\n```\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"screen-shots/ask-ai-01.png\" alt=\"Ask AI Screenshot 1\" width=\"602\" /\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"screen-shots/ask-ai-02.png\" alt=\"Ask AI Screenshot 2\" width=\"631\" /\u003e\n\u003c/p\u003e\n\nWith Ask AI enabled, users can:\n\n- Get intelligent answers based on your documentation\n- Access AI assistance with a simple keyboard shortcut\n- Receive context-aware responses tailored to your content\n\nSee the [askAi option](#theme-options) in Theme Options below for configuration details.\n\n## Installation\n\n```shell\nnpm install --save @easyops-cn/docusaurus-search-local\n# or\nyarn add @easyops-cn/docusaurus-search-local\n```\n\n## Usage\n\nAdd `@easyops-cn/docusaurus-search-local` into your docusaurus themes.\n\n```js\n// In your `docusaurus.config.js`:\nmodule.exports = {\n  // ... Your other configurations.\n  themes: [\n    // ... Your other themes.\n    [\n      require.resolve(\"@easyops-cn/docusaurus-search-local\"),\n      /** @type {import(\"@easyops-cn/docusaurus-search-local\").PluginOptions} */\n      ({\n        // ... Your options.\n        // `hashed` is recommended as long-term-cache of index file is possible.\n        hashed: true,\n\n        // For Docs using Chinese, it is recomended to set:\n        // language: [\"en\", \"zh\"],\n\n        // Customize the keyboard shortcut to focus search bar (default is \"mod+k\"):\n        // searchBarShortcutKeymap: \"s\", // Use 'S' key\n        // searchBarShortcutKeymap: \"ctrl+shift+f\", // Use Ctrl+Shift+F\n\n        // If you're using `noIndex: true`, set `forceIgnoreNoIndex` to enable local index:\n        // forceIgnoreNoIndex: true,\n\n        // Enable Ask AI integration:\n        // askAi: {\n        //   project: \"your-project-name\",\n        //   apiUrl: \"https://your-api-url.com/api/stream\",\n        //   hotkey: \"cmd+I\", // Optional: keyboard shortcut to trigger Ask AI\n        // },\n      }),\n    ],\n  ],\n};\n```\n\n\u003e Notice: We present this as a theme instead of plugin now, see [this comment](https://github.com/facebook/docusaurus/issues/6488#issuecomment-1024124096).\n\n## Theme Options\n\n| Name                              | Type                                                                        | Default   | Description                                                                                                                                                                                                                                                                                                                                                 |\n| --------------------------------- | --------------------------------------------------------------------------- | --------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| indexDocs                         | boolean                                                                     | `true`    | Whether to index docs.                                                                                                                                                                                                                                                                                                                                      |\n| indexBlog                         | boolean                                                                     | `true`    | Whether to index blog.                                                                                                                                                                                                                                                                                                                                      |\n| indexPages                        | boolean                                                                     | `false`   | Whether to index pages.                                                                                                                                                                                                                                                                                                                                     |\n| docsRouteBasePath                 | string \\| string[]                                                          | `\"/docs\"` | Base route path(s) of docs. Slash at beginning is not required. Note: for [docs-only mode](https://docusaurus.io/docs/docs-introduction#docs-only-mode), this needs to be the same as `routeBasePath` in your `@docusaurus/preset-classic` config e.g., `\"/\"`.                                                                                              |\n| blogRouteBasePath                 | string \\| string[]                                                          | `\"/blog\"` | Base route path(s) of blog. Slash at beginning is not required.                                                                                                                                                                                                                                                                                             |\n| language                          | string \\| string[]                                                          | `\"en\"`    | All [lunr-languages](https://github.com/MihaiValentin/lunr-languages) supported languages, + `zh` 🔥.                                                                                                                                                                                                                                                       |\n| hashed                            | boolean \\| `\"filename\"` \\| `\"query\"`                                        | `false`   | Whether to add a hashed query when fetching index (based on the content hash of all indexed `*.md` in `docsDir` and `blogDir` if applicable). Setting to `\"filename\"` will save hash in filename instead of query.                                                                                                                                          |\n| docsDir                           | string \\| string[]                                                          | `\"docs\"`  | The dir(s) of docs to get the content hash, it's relative to the dir of your project.                                                                                                                                                                                                                                                                       |\n| blogDir                           | string \\| string[]                                                          | `\"blog\"`  | Just like the `docsDir` but applied to blog.                                                                                                                                                                                                                                                                                                                |\n| removeDefaultStopWordFilter       | boolean \\| string[]                                                         | `[]`      | Sometimes people (E.g., us) want to keep the English stop words as indexed, since they maybe are relevant in programming docs. Set a language list to remove their default stop word filter, `true` is equivalent to `[\"en\"]`.                                                                                                                              |\n| removeDefaultStemmer              | boolean                                                                     | `false`   | Enable this if you want to be able to search for any partial word at the cost of search performance.                                                                                                                                                                                                                                                        |\n| highlightSearchTermsOnTargetPage  | boolean                                                                     | `false`   | Highlight search terms on target page.                                                                                                                                                                                                                                                                                                                      |\n| searchResultLimits                | number                                                                      | `8`       | Limit the search results.                                                                                                                                                                                                                                                                                                                                   |\n| searchResultContextMaxLength      | number                                                                      | `50`      | Set the max length of characters of each search result to show.                                                                                                                                                                                                                                                                                             |\n| explicitSearchResultPath          | boolean                                                                     | `false`   | Whether an explicit path to a heading should be presented on a suggestion template.                                                                                                                                                                                                                                                                         |\n| ignoreFiles                       | string \\| RegExp \\| (string \\| RegExp)[]                                    | `[]`      | Set the match rules to ignore some routes. Put a string if you want an exact match, or put a regex if you want a partial match. Note: without the website base url.                                                                                                                                                                                         |\n| ignoreCssSelectors                | string \\| string[]                                                          | `[]`      | A list of css selectors to ignore when indexing each page.                                                                                                                                                                                                                                                                                                  |\n| searchBarShortcut                 | boolean                                                                     | `true`    | Whether to enable keyboard shortcut to focus in search bar.                                                                                                                                                                                                                                                                                                 |\n| searchBarShortcutHint             | boolean                                                                     | `true`    | Whether to show keyboard shortcut hint in search bar. Disable it if you need to hide the hint while shortcut is still enabled.                                                                                                                                                                                                                              |\n| searchBarShortcutKeymap           | string                                                                      | `\"mod+k\"` | Custom keyboard shortcut to focus the search bar. Supports formats like: `\"s\"` for single key, `\"ctrl+k\"` for key combinations, `\"mod+k\"` for Command+K (Mac) / Ctrl+K (others) - recommended cross-platform option, `\"ctrl+shift+k\"` for multiple modifiers.                                                                                               |\n| searchBarPosition                 | `\"auto\"` \\| `\"left\"` \\| `\"right\"`                                           | `\"auto\"`  | The side of the navbar the search bar should appear on. By default, it will try to autodetect based on your docusaurus config according to [the docs](https://docusaurus.io/docs/api/themes/configuration#navbar-search).                                                                                                                                   |\n| docsPluginIdForPreferredVersion   | string                                                                      |           | When you're using multi-instance of docs, set the docs plugin id which you'd like to check the preferred version with, for the search index.                                                                                                                                                                                                                |\n| zhUserDict                        | string                                                                      |           | Provide your custom dict for language of zh, [see here](https://github.com/fxsjy/jieba#%E8%BD%BD%E5%85%A5%E8%AF%8D%E5%85%B8)                                                                                                                                                                                                                                |\n| zhUserDictPath                    | string                                                                      |           | Provide the file path to your custom dict for language of zh, E.g.: `path.resolve(\"./src/zh-dict.txt\")`                                                                                                                                                                                                                                                     |\n| searchContextByPaths              | `(string \\| { label: string \\| Record\u003cstring, string\u003e; path: string; } )[]` | `[]`      | Provide an list of sub-paths as separate search context, E.g.: `[\"docs\", \"community\", \"legacy/resources\"]`. It will create multiple search indexes by these paths.                                                                                                                                                                                          |\n| hideSearchBarWithNoSearchContext  | boolean                                                                     | `false`   | Whether to hide the search bar when no search context was matched. By default, if `searchContextByPaths` is set, pages which are not matched with it will be considered as with a search context of ROOT. By setting `hideSearchBarWithNoSearchContext: true`, these pages will be considered as with NO search context, and the search bar will be hidden. |\n| useAllContextsWithNoSearchContext | boolean                                                                     | `false`   | Whether to show results from all the contexts if no context is provided. This option should not be used with `hideSearchBarWithNoSearchContext: true` as this would show results when there is no search context. This will duplicate indexes and might have a performance cost depending on the index sizes.                                               |\n| `forceIgnoreNoIndex`              | boolean                                                                     | `false`   | Force enable search index even if `noIndex: true` is set, this also affects unlisted articles.                                                                                                                                                                                                                                                              |\n| `fuzzyMatchingDistance`           | number                                                                      | `1`       | Set the edit distance for fuzzy matching during searches.                                                                                                                                                                                                                                                                                                   |\n| `askAi`                           | object                                                                      |           | Configuration for Ask AI widget integration. When not set, the Ask AI feature will be disabled. Required properties: `project` (string), `apiUrl` (string). Optional: `hotkey` (string, e.g., \"cmd+I\"). See [Ask AI Support](#-ask-ai-support) for more details.                                                                                            |\n\n### I18N\n\nSince v0.25.0, we support [docusaurus i18n system](\u003c(https://docusaurus.io/docs/i18n/introduction)\u003e), and provided `en` / `de` / `vi` and `zh-CN` translations out of the box.\n\nFor other languages, please follow the official tutorial about how to [translate plugin data](https://docusaurus.io/docs/i18n/tutorial#translate-plugin-data). And translate `theme.SearchBar.*` and `theme.SearchPage.*` in `i18n/*/code.json`.\n\nTranslations by options is dropped since v0.25.0.\n\n\u003cdetails\u003e\n\u003csummary\u003eSee translation options for \u0026lt;0.25.0\u003c/summary\u003e\nTo make this theme localized, pass a `translations` option which defaults to:\n\n```json\n{\n  \"translations\": {\n    \"search_placeholder\": \"Search\",\n    \"see_all_results\": \"See all results\",\n    \"no_results\": \"No results.\",\n    \"search_results_for\": \"Search results for \\\"{{ keyword }}\\\"\",\n    \"search_the_documentation\": \"Search the documentation\",\n    \"count_documents_found\": \"{{ count }} document found\",\n    \"count_documents_found_plural\": \"{{ count }} documents found\",\n    \"no_documents_were_found\": \"No documents were found\"\n  }\n}\n```\n\nNote that `*_plural` can be omitted if it is the same as singular.\n\n\u003c/details\u003e\n\n## Custom Styles\n\nThis theme is shipped with polished styles just like the Algolia Search on the Docusaurus v2 website. Feel free to override these css custom properties (css variables) below.\n\n| Var                                      | Description                               | Default (light)                                                        | Default (dark)                                          |\n| ---------------------------------------- | ----------------------------------------- | ---------------------------------------------------------------------- | ------------------------------------------------------- |\n| --search-local-modal-background          | The search modal background               | `#f5f6f7`                                                              | `var(--ifm-background-color)`                           |\n| --search-local-modal-shadow              | The search modal box-shadow               | `inset 1px 1px 0 0 hsla(0, 0%, 100%, 0.5),`\u003cbr /\u003e`0 3px 8px 0 #555a64` | `inset 1px 1px 0 0 #2c2e40,`\u003cbr /\u003e`0 3px 8px 0 #000309` |\n| --search-local-modal-width               | The width of search modal by default      | `560px`                                                                | -                                                       |\n| --search-local-modal-width-sm            | The width of search modal on small screen | `340px`                                                                | -                                                       |\n| --search-local-spacing                   | The padding fo search modal               | `12px`                                                                 | -                                                       |\n| --search-local-hit-background            | The background of each suggestion         | `#fff`                                                                 | `var(--ifm-color-emphasis-100)`                         |\n| --search-local-hit-shadow                | The box-shadow of each suggestion         | `0 1px 3px 0 #d4d9e1`                                                  | `none`                                                  |\n| --search-local-hit-color                 | The text color of suggestions             | `#444950`                                                              | `var(--ifm-font-color-base)`                            |\n| --search-local-hit-height                | The height of each suggestion             | `56px`                                                                 | -                                                       |\n| --search-local-highlight-color           | The highlight text color of suggestions   | `var(--ifm-color-primary)`                                             | -                                                       |\n| --search-local-muted-color               | The text color of some secondary content  | `#969faf`                                                              | `var(--ifm-color-secondary-darkest)`                    |\n| --search-local-icon-stroke-width         | The icon stroke width of suggestions      | `1.4`                                                                  | -                                                       |\n| --search-local-hit-active-color          | The text color of selected suggestion     | `var(--ifm-color-white)`                                               | -                                                       |\n| --search-local-input-active-border-color | The border color of input box when active | `var(--ifm-color-primary)`                                             | -                                                       |\n\nE.g.:\n\n```css\n:root {\n  --search-local-modal-width: 480px;\n  --search-local-highlight-color: #5468ff;\n}\n\nhtml[data-theme=\"dark\"] {\n  --search-local-highlight-color: #d23669;\n}\n```\n\n## Trouble Shooting\n\nWhen building your docs project, Set the env `DEBUG=search-local:*` to enable [debug](https://github.com/visionmedia/debug) logs.\n\n```shell\n# In your docs project:\nDEBUG=search-local:* yarn build\n```\n\nIn case some specific errors occurred:\n\n- `Error: Cannot mix different versions of joi schemas`:\n\n  - Try using @easyops-cn/docusaurus-search-local \u003e= v0.16.0 with Docusaurus \u003e= v2.0.0-alpha.73\n  - Try using @easyops-cn/docusaurus-search-local between v0.14.0 and v0.15.1 with Docusaurus between v2.0.0-alpha.68 and v2.0.0-alpha.72\n  - Or try using @easyops-cn/docusaurus-search-local \u003c= v0.13.1 with Docusaurus \u003c= v2.0.0-alpha.66\n\n- `Module not found: Error: Can't resolve '@docusaurus/useRouteContext'`:\n  - Try using @easyops-cn/docusaurus-search-local \u003e= v0.25.0 with Docusaurus \u003e= v2.0.0-beta.18\n  - Try using @easyops-cn/docusaurus-search-local \u003c v0.25.0 with Docusaurus \u003c v2.0.0-beta.18\n\n## Further Reading\n\n- [多语言全文搜索](https://wangshenwei.com/multilingual-full-text-search/)\n\n## Contributing\n\nSee [contributing guide](CONTRIBUTING.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feasyops-cn%2Fdocusaurus-search-local","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feasyops-cn%2Fdocusaurus-search-local","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feasyops-cn%2Fdocusaurus-search-local/lists"}