🌐 AI搜索 & 代理 主页
Skip to content

Commit 44db3d1

Browse files
authored
Update main-docs.js
1 parent 006ac67 commit 44db3d1

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

docs/components/main-docs.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,13 @@ export default {
1818
},
1919
computed: {
2020
docs() {
21-
return splitReadme(this.readme)
21+
return splitReadme(this.readme || '')
2222
},
2323
titleLead() {
24-
return this.docs.titleLead
24+
return this.docs.titleLead || ''
2525
},
2626
body() {
27-
return this.docs.body
27+
return this.docs.body || this.readme
2828
},
2929
docsPath() {
3030
return this.$route.path
@@ -37,9 +37,9 @@ export default {
3737
domProps: { innerHTML: this.titleLead }
3838
})
3939
// CarbonAd
40-
const $carbonAd = h(CarbonAd, { key: `ad-${this.$route.path}` })
40+
const $carbonAd = h(CarbonAd, { key: `ad-${this.docPath}` })
4141
// Quick links
42-
const $quickLinks = h(QuickLinks, { key: `quick-${this.$route.path}` })
42+
const $quickLinks = h(QuickLinks, { key: `quick-${this.docsPath}` })
4343
// Body section
4444
const $bodySection = h(Section, {
4545
props: { play: true },

0 commit comments

Comments
 (0)