Skip to content

Commit 47b2fc5

Browse files
committedSep 9, 2023
feat: support currentLocale site config
1 parent 807f774 commit 47b2fc5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

‎module/src/runtime/plugin/defaults.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ export default defineNuxtPlugin({
5050
useServerHead({
5151
templateParams: { site: { name: siteConfig.name, url: siteConfig.url }, separator: siteConfig.titleSeparator },
5252
// TODO integrate with nuxt/i18n
53-
htmlAttrs: { lang: siteConfig.deaultLocale },
53+
htmlAttrs: { lang: () => siteConfig?.currentLocale },
5454
titleTemplate: '%s %separator %site.name',
5555
})
5656

@@ -79,7 +79,7 @@ export default defineNuxtPlugin({
7979
defineWebSite({
8080
name: () => siteConfig?.name || '',
8181
// TODO integrate with nuxt/i18n
82-
inLanguage: () => siteConfig?.defaultLocale || '',
82+
inLanguage: () => siteConfig?.currentLocale || '',
8383
description: () => siteConfig?.description || '',
8484
}),
8585
defineWebPage(),

0 commit comments

Comments
 (0)
Please sign in to comment.