fix(env): lire UMAMI_WEBSITE_ID via process.env (runtime, pas build)
Some checks are pending
Deploy info-canicule / deploy (push) Waiting to run
Some checks are pending
Deploy info-canicule / deploy (push) Waiting to run
import.meta.env est résolu au build (par Vite), donc le snippet Umami restait absent à l'exécution puisque .env est seulement disponible au runtime côté container. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
86352eb436
commit
f64394f69e
1 changed files with 2 additions and 2 deletions
|
|
@ -20,8 +20,8 @@ const {
|
||||||
|
|
||||||
const canonicalUrl = canonical ?? new URL(Astro.url.pathname, SITE).toString();
|
const canonicalUrl = canonical ?? new URL(Astro.url.pathname, SITE).toString();
|
||||||
const fullOgImage = ogImage.startsWith('http') ? ogImage : `${SITE}${ogImage}`;
|
const fullOgImage = ogImage.startsWith('http') ? ogImage : `${SITE}${ogImage}`;
|
||||||
const umamiId = import.meta.env.UMAMI_WEBSITE_ID;
|
const umamiId = process.env.UMAMI_WEBSITE_ID;
|
||||||
const umamiSrc = import.meta.env.UMAMI_SRC ?? 'https://analytics.nocleus.com/script.js';
|
const umamiSrc = process.env.UMAMI_SRC ?? 'https://analytics.nocleus.com/script.js';
|
||||||
|
|
||||||
const jsonLd = {
|
const jsonLd = {
|
||||||
'@context': 'https://schema.org',
|
'@context': 'https://schema.org',
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue