mirror of
https://github.com/pengzhanbo/vuepress-theme-plume.git
synced 2026-04-23 10:58:13 +08:00
fix(theme): 修复 文章 设置 article 为 false 时未被正确过滤的问题
This commit is contained in:
parent
1d63a9c4f4
commit
edf54568ea
@ -12,7 +12,11 @@ export const usePostAllIndex = (): PostIndexRef => postIndex
|
||||
// 在首页文章列表的,默认排除掉 note中的文章,除非显示声明 article
|
||||
export const usePostIndex = (): PostIndexRef => {
|
||||
const postList = postIndex.value.filter((post) => {
|
||||
return !post.isNote || post.article === true
|
||||
if (post.isNote) {
|
||||
return post.article === true
|
||||
} else {
|
||||
return post.article !== false
|
||||
}
|
||||
})
|
||||
return ref(postList)
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user