2025-09-10 16:50:31 +01:00
|
|
|
import { dev } from '$app/environment';
|
2025-11-24 01:00:50 +01:00
|
|
|
import { initPosthog } from '$lib/utils/services/posthog';
|
|
|
|
|
import { initSentry } from '$lib/utils/services/sentry';
|
2024-12-26 07:23:46 +01:00
|
|
|
|
|
|
|
|
export function setupAnalytics() {
|
|
|
|
|
// Set up sentry
|
|
|
|
|
initSentry();
|
|
|
|
|
|
|
|
|
|
// Set up posthog
|
|
|
|
|
initPosthog();
|
|
|
|
|
|
|
|
|
|
// Disable umami on localhost
|
|
|
|
|
if (dev) {
|
|
|
|
|
localStorage.setItem('umami.disabled', '1');
|
|
|
|
|
}
|
|
|
|
|
}
|