Skip to content

Commit 54a46b5

Browse files
author
JavasHub
committed
update theme
1 parent dbe124e commit 54a46b5

File tree

2 files changed

+3
-40
lines changed

2 files changed

+3
-40
lines changed

config/爬虫_imlyk.js

Lines changed: 2 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -10,52 +10,15 @@ new Crawler({
1010
ignoreQueryParams: ["source", "utm_*"],
1111
actions: [
1212
{
13-
indexName: "javashub_cn_9ju9ru2as7_articles",
13+
indexName: "javashub",
1414
pathsToMatch: ["https://javashub.cn/**", "https://www.javashub.cn/**"],
1515
recordExtractor: ({ url, $, helpers }) => {
1616
return helpers.article({ $, url });
1717
},
1818
},
19-
{
20-
indexName: "javashub_cn_9ju9ru2as7_products",
21-
pathsToMatch: ["https://javashub.cn/**", "https://www.javashub.cn/**"],
22-
recordExtractor: ({ url, $, helpers }) => {
23-
return helpers.product({ $, url });
24-
},
25-
},
26-
{
27-
indexName: "javashub_cn_9ju9ru2as7_pages",
28-
pathsToMatch: ["https://javashub.cn/**", "https://www.javashub.cn/**"],
29-
recordExtractor: ({ url, $, helpers, contentLength, fileType }) => {
30-
return helpers.page({ $, url, contentLength, fileType });
31-
},
32-
},
3319
],
3420
initialIndexSettings: {
35-
javashub_cn_9ju9ru2as7_articles: {
36-
distinct: true,
37-
attributeForDistinct: "url",
38-
searchableAttributes: [
39-
"unordered(keywords)",
40-
"unordered(title)",
41-
"unordered(description)",
42-
"url",
43-
],
44-
customRanking: ["asc(depth)"],
45-
attributesForFaceting: ["category"],
46-
},
47-
javashub_cn_9ju9ru2as7_products: {
48-
distinct: true,
49-
attributeForDistinct: "url",
50-
searchableAttributes: [
51-
"unordered(name)",
52-
"unordered(description)",
53-
"url",
54-
],
55-
customRanking: ["asc(depth)"],
56-
attributesForFaceting: ["category"],
57-
},
58-
javashub_cn_9ju9ru2as7_pages: {
21+
javashub: {
5922
distinct: true,
6023
attributeForDistinct: "url",
6124
searchableAttributes: [

src/.vuepress/theme.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ export default hopeTheme({
145145
docsearch: {
146146
appId: "9JU9RU2AS7",
147147
apiKey: "5932aa30edad2e9ef2df7a4b0289077d",
148-
indexName: "javashub", // javashub
148+
indexName: "javashub",
149149
locales: {
150150
"/": {
151151
placeholder: "搜索文档",

0 commit comments

Comments
 (0)