Skip to content

Commit

Permalink
Merge pull request #42 from game-node-app/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
Lamarcke authored Mar 19, 2024
2 parents 1a004e7 + 965cb32 commit 966fa48
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/components/general/MatomoTracker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,15 +58,21 @@ const MatomoTracker = () => {
}, [hasAcceptedCookies, showCookieConsentNotification]);

useEffect(() => {
console.log("Checking if Matomo should be initialized");
console.log(
`Conditional: ${!IS_DEV_ENV && MATOMO_URL && MATOMO_SITE_ID}`,
);
if (!IS_DEV_ENV && MATOMO_URL && MATOMO_SITE_ID) {
console.log(
`Matomo initialized! URL: ${MATOMO_URL} | SiteID: ${MATOMO_SITE_ID}`,
);
init({
url: MATOMO_URL,
siteId: MATOMO_SITE_ID,
});
}
}, []);

useEffect(() => {}, []);
return <></>;
};

Expand Down

0 comments on commit 966fa48

Please sign in to comment.