We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b2edc6f commit dab83f1Copy full SHA for dab83f1
src/components/PostLayout/PostLayout.vue
@@ -1,14 +1,15 @@
1
<script setup>
2
import { useData } from "vitepress";
3
+import { computed } from "vue";
4
import DefaultTheme from "vitepress/theme";
5
import PostComment from "@/components/PostComment/PostComment.vue";
6
import PostHeader from "@/components/PostHeader/PostHeader.vue";
7
const { Layout } = DefaultTheme;
8
9
const { frontmatter } = useData();
10
-const showHeader = Boolean(frontmatter.value.title);
11
-const showComments = frontmatter.value.comment === true;
+const showHeader = computed(() => Boolean(frontmatter.value.title));
12
+const showComments = computed(() => frontmatter.value.comment === true);
13
</script>
14
15
<template>
0 commit comments