Skip to content

Commit

Permalink
Fixed unique page title for error page
Browse files Browse the repository at this point in the history
- error page shouldn't be crawled so description is not necessary
- updated eslint for nuxt/vue3 non-issues
  • Loading branch information
LucasSteer committed Jul 30, 2023
1 parent 165bb26 commit dbca32f
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 11 deletions.
5 changes: 3 additions & 2 deletions .eslintrc.json
Expand Up @@ -19,11 +19,12 @@
},
"overrides": [
{
"files": ["**/pages/**/*.{js,ts,jsx,tsx,vue}"],
"files": ["**/pages/**/*.{js,ts,jsx,tsx,vue}", "error.vue"],
"rules": { "vue/multi-word-component-names": "off" }
}
],
"globals": {
"useHead": false
"useHead": false,
"definePageMeta": false
}
}
22 changes: 13 additions & 9 deletions error.vue
Expand Up @@ -16,16 +16,20 @@
</NuxtLayout>
</template>

<script>
<script setup>
import { useThemeStore } from '@/stores/theme';
import { mapStores } from 'pinia';
export default {
name: 'ErrorPage',
props: ['error'],
const themeStore = useThemeStore();
defineProps({
error: Object,
});
definePageMeta({
layout: 'error',
computed: {
...mapStores(useThemeStore),
},
};
});
useHead({
title: 'Page Not Found | Lucas Steer',
});
</script>

0 comments on commit dbca32f

Please sign in to comment.