File tree Expand file tree Collapse file tree 2 files changed +44
-0
lines changed
src/runtime/components/app Expand file tree Collapse file tree 2 files changed +44
-0
lines changed Original file line number Diff line number Diff line change 33const nuxtifyConfig = useNuxtifyConfig ()
44const dialog = useDialog ()
55const toast = useToast ()
6+ const errorMessage = useErrorMessage ()
67
78// Page info
89useNuxtifySiteTitle ()
@@ -11,6 +12,9 @@ useServerSeoMeta({
1112 description: ` This is the ${nuxtifyConfig .brand ?.name } playground. ` ,
1213})
1314
15+ // Component state
16+ errorMessage .value = ' This is an error message.'
17+
1418// Functions
1519const clickDialog = () => {
1620 // Dialog
@@ -106,6 +110,16 @@ const clickToast = () => {
106110 </v-col >
107111 </v-row >
108112
113+ <!-- App error -->
114+ <v-row >
115+ <v-col cols =" 12" >
116+ <v-card class =" pa-4" >
117+ <h2 >AppError</h2 >
118+ <AppError />
119+ </v-card >
120+ </v-col >
121+ </v-row >
122+
109123 <!-- App logo override -->
110124 <v-row >
111125 <v-col cols =" 12" >
Original file line number Diff line number Diff line change 1+ <script setup lang="ts">
2+ import { useErrorMessage } from ' #imports'
3+
4+ const errorMessage = useErrorMessage ()
5+ const isDev = import .meta .dev
6+ </script >
7+
8+ <template >
9+ <v-alert
10+ v-if =" errorMessage"
11+ type =" error"
12+ density =" compact"
13+ variant =" text"
14+ :icon =" false"
15+ class =" text-body-2 pa-0"
16+ >
17+ {{ errorMessage }}
18+
19+ <!-- DEBUG -->
20+ <div
21+ v-if =" isDev"
22+ class =" mt-2"
23+ >
24+ <h2 class =" text-h6 text-black" >
25+ Debug
26+ </h2 >
27+ <pre >{{ errorMessage }}</pre >
28+ </div >
29+ </v-alert >
30+ </template >
You can’t perform that action at this time.
0 commit comments