app.vue 689 B

12345678910111213141516171819202122232425262728293031323334353637
  1. <template>
  2. <Html :lang="i18nHead.htmlAttrs.lang" :dir="i18nHead.htmlAttrs.dir">
  3. <div id="top" />
  4. <LayoutNavigation />
  5. <nuxt-page />
  6. <LayoutFooter />
  7. </Html>
  8. </template>
  9. <script setup lang="ts">
  10. import UrlUtils from '~/services/utils/urlUtils'
  11. const layoutStore = useLayoutStore()
  12. layoutStore.resetAnchoredSections()
  13. const i18nHead = useLocaleHead({
  14. addDirAttribute: true,
  15. identifierAttribute: 'id',
  16. addSeoAttributes: true,
  17. })
  18. const route = useRoute()
  19. const runtimeConfig = useRuntimeConfig()
  20. useHead(() => ({
  21. link: [
  22. {
  23. rel: 'canonical',
  24. href: UrlUtils.join(runtimeConfig.public.siteUrl as string, route.path),
  25. },
  26. ],
  27. }))
  28. </script>