mirror of
https://github.com/theoludwig/theoludwig.git
synced 2025-01-23 13:19:36 +01:00
fix: use Plausible
This commit is contained in:
parent
e68cb08a6f
commit
d91feb8de4
@ -9,6 +9,9 @@ import {
|
|||||||
getTranslations,
|
getTranslations,
|
||||||
setRequestLocale,
|
setRequestLocale,
|
||||||
} from "next-intl/server"
|
} from "next-intl/server"
|
||||||
|
import Script from "next/script"
|
||||||
|
|
||||||
|
const DOMAIN = "theoludwig.fr"
|
||||||
|
|
||||||
export const generateMetadata = async ({
|
export const generateMetadata = async ({
|
||||||
params,
|
params,
|
||||||
@ -18,7 +21,7 @@ export const generateMetadata = async ({
|
|||||||
const title = t("meta.title")
|
const title = t("meta.title")
|
||||||
const description = `${title} - ${t("meta.description")}`
|
const description = `${title} - ${t("meta.description")}`
|
||||||
const image = "/images/logo.webp"
|
const image = "/images/logo.webp"
|
||||||
const url = new URL("https://theoludwig.fr")
|
const url = new URL(`https://${DOMAIN}`)
|
||||||
const locales = LOCALES.join(", ")
|
const locales = LOCALES.join(", ")
|
||||||
|
|
||||||
return {
|
return {
|
||||||
@ -74,6 +77,12 @@ const LocaleLayout: React.FC<LocaleLayoutProps> = async (props) => {
|
|||||||
<NextIntlClientProvider messages={messages}>
|
<NextIntlClientProvider messages={messages}>
|
||||||
{children}
|
{children}
|
||||||
</NextIntlClientProvider>
|
</NextIntlClientProvider>
|
||||||
|
|
||||||
|
<Script
|
||||||
|
defer
|
||||||
|
data-domain={DOMAIN}
|
||||||
|
src="https://plausible.theoludwig.fr/js/script.js"
|
||||||
|
/>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
)
|
)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user