@easyops-cn/docusaurus-search-local 0.23.2 → 0.23.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/README.md +1 -1
- package/dist/server/server/utils/getIndexHash.js +2 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [0.23.3](https://www.github.com/easyops-cn/docusaurus-search-local/compare/v0.23.2...v0.23.3) (2022-05-18)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* Update getIndexHash.ts to support mdx and traverseAll ([#172](https://www.github.com/easyops-cn/docusaurus-search-local/issues/172)) ([717942e](https://www.github.com/easyops-cn/docusaurus-search-local/commit/717942e9caf36e37a0f119d9fdaa50e591339d9c))
|
|
11
|
+
|
|
5
12
|
### [0.23.2](https://www.github.com/easyops-cn/docusaurus-search-local/compare/v0.23.1...v0.23.2) (2022-04-25)
|
|
6
13
|
|
|
7
14
|
|
package/README.md
CHANGED
|
@@ -73,7 +73,7 @@ module.exports = {
|
|
|
73
73
|
| indexDocs | boolean | `true` | Whether to index docs. |
|
|
74
74
|
| indexBlog | boolean | `true` | Whether to index blog. |
|
|
75
75
|
| indexPages | boolean | `false` | Whether to index pages. |
|
|
76
|
-
| docsRouteBasePath | string \| string[] | `"/docs"` | Base route path(s) of docs. Slash at beginning is not required.
|
|
76
|
+
| 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., `"/"`. |
|
|
77
77
|
| blogRouteBasePath | string \| string[] | `"/blog"` | Base route path(s) of blog. Slash at beginning is not required. |
|
|
78
78
|
| language | string \| string[] | `"en"` | All [lunr-languages](https://github.com/MihaiValentin/lunr-languages) supported languages, + `zh` 🔥. |
|
|
79
79
|
| hashed | boolean | `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) |
|
|
@@ -22,7 +22,7 @@ function getIndexHash(config) {
|
|
|
22
22
|
console.warn(`Warn: \`${dirField}\` is not a directory: "${dir}".`);
|
|
23
23
|
}
|
|
24
24
|
else {
|
|
25
|
-
files.push(...klaw_sync_1.default(dir, { nodir: true, filter: markdownFilter }));
|
|
25
|
+
files.push(...klaw_sync_1.default(dir, { nodir: true, filter: markdownFilter, traverseAll: true }));
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
28
|
}
|
|
@@ -48,5 +48,5 @@ function getIndexHash(config) {
|
|
|
48
48
|
}
|
|
49
49
|
exports.getIndexHash = getIndexHash;
|
|
50
50
|
function markdownFilter(item) {
|
|
51
|
-
return item.path.endsWith(".md");
|
|
51
|
+
return item.path.endsWith(".md") || item.path.endsWith(".mdx");
|
|
52
52
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@easyops-cn/docusaurus-search-local",
|
|
3
|
-
"version": "0.23.
|
|
3
|
+
"version": "0.23.3",
|
|
4
4
|
"description": "An offline/local search plugin for Docusaurus v2.",
|
|
5
5
|
"repository": "https://github.com/easyops-cn/docusaurus-search-local",
|
|
6
6
|
"homepage": "https://github.com/easyops-cn/docusaurus-search-local",
|