Skip to content

Commit 699e2a2

Browse files
committed
feat: signup page update content import
1 parent 46c9bf3 commit 699e2a2

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

pages/signup.vue

+12-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<template>
2-
<main :class="[`page page-${tag}`]">
2+
<main class="page page-signup">
33
<div id="section-signup">
44
<div class="grid-center-noGutter">
55
<div class="col-8_sm-12">
@@ -22,12 +22,21 @@
2222
</template>
2323

2424
<script setup>
25+
2526
// ======================================================================== Data
26-
const tag = 'signup'
27-
const { data } = await useAsyncData( async () => {
27+
const generalStore = useGeneralStore()
28+
const { $GetSeo, $CompileSeo } = useNuxtApp()
29+
const { data } = await useAsyncData('core', async () => {
2830
return queryContent('core').find()
2931
})
3032
33+
// ==================================================================== Watchers
34+
watch(data, async (val) => {
35+
await generalStore.getBaseData('general')
36+
await generalStore.getBaseData({ key: 'signup', data: val.find((item) => item._file === 'core/signup.json') })
37+
useHead($CompileSeo($GetSeo('general', 'signup')))
38+
}, { immediate: true })
39+
3140
// ==================================================================== Computed
3241
const content = computed(() => {
3342
const signup = data._rawValue.find((item) => item._file === 'core/signup.json')

0 commit comments

Comments
 (0)