diff --git a/package.json b/package.json index 04b98a3..30c1f4d 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "minista", "description": "Next.js Like Development with 100% Static Generate", - "version": "2.8.0", + "version": "2.8.1", "bin": { "minista": "./bin/minista.js" }, diff --git a/src/render.tsx b/src/render.tsx index 1549759..f84cf0e 100644 --- a/src/render.tsx +++ b/src/render.tsx @@ -12,9 +12,15 @@ export async function renderHtml( const staticHelmet = (data: string) => { return data.replace(/data-react-helmet="true"/g, "") } + const htmlAttributes = Object.hasOwn( + helmet.htmlAttributes.toComponent(), + "lang" + ) + ? helmet.htmlAttributes.toString() + : `lang="ja" ${helmet.htmlAttributes.toString()}` return ` - +
diff --git a/user/src/pages/index.tsx b/user/src/pages/index.tsx index ac1d659..54f50e4 100644 --- a/user/src/pages/index.tsx +++ b/user/src/pages/index.tsx @@ -6,6 +6,9 @@ const PageHome = () => {