Skip to content

Commit

Permalink
✨ (layout) lighten layout key
Browse files Browse the repository at this point in the history
  • Loading branch information
Tahul committed Jun 1, 2021
1 parent 61fe392 commit cfb8148
Showing 1 changed file with 2 additions and 15 deletions.
17 changes: 2 additions & 15 deletions src/defaultTheme/components/organisms/AppLayout.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,26 +21,13 @@
</template>

<script>
import { defineComponent, ref, useContext, watch } from '@nuxtjs/composition-api'
import { computed, defineComponent, useContext } from '@nuxtjs/composition-api'
export default defineComponent({
setup() {
const { $docus } = useContext()
const layout = ref({
...$docus.layout.value
})
watch(
$docus.layout,
newVal => {
layout.value = newVal
},
{
immediate: true,
deep: true
}
)
const layout = computed(() => $docus.layout.value)
return {
layout
Expand Down

0 comments on commit cfb8148

Please sign in to comment.