Skip to content

Commit

Permalink
chore(lang): lang element based on frontmatter or default locale (jac…
Browse files Browse the repository at this point in the history
…kyzha0#819)

default locale

Signed-off-by: Aaron <[email protected]>
  • Loading branch information
aarnphm authored Feb 7, 2024
1 parent ce413b4 commit 2578597
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion quartz/components/renderPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,10 @@ export function renderPage(
</div>
)

const lang = componentData.frontmatter?.lang ?? cfg.locale.split("-")[0]

const doc = (
<html>
<html lang={lang}>
<Head {...componentData} />
<body data-slug={slug}>
<div id="quartz-root" class="page">
Expand Down

0 comments on commit 2578597

Please sign in to comment.