mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 16:43:55 +00:00
27 lines
549 B
Vue
27 lines
549 B
Vue
|
<template>
|
||
|
<div class="relative font-sans" n="green6">
|
||
|
<div class="container max-w-200 mx-auto py-10 px-4">
|
||
|
<h1>{{ error.message }}</h1>
|
||
|
There was an error 😱
|
||
|
|
||
|
<button @click="handleError">
|
||
|
Clear error
|
||
|
</button>
|
||
|
<NuxtLink to="/404">
|
||
|
Trigger another error
|
||
|
</NuxtLink>
|
||
|
<NuxtLink to="/">
|
||
|
Navigate home
|
||
|
</NuxtLink>
|
||
|
</div>
|
||
|
</div>
|
||
|
</template>
|
||
|
|
||
|
<script setup lang="ts">
|
||
|
defineProps({
|
||
|
error: Object
|
||
|
})
|
||
|
|
||
|
const handleError = () => clearError({ redirect: '/' })
|
||
|
</script>
|