📈 Open source, privacy-first web analytics — a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!
TypeScript chartsclickhousedockergdprgoogle-analyticsmetricsmonitoringmysqlnestjsprivacyredisself-hostedselfhostedstatisticstailwindcssweb-analyticswebanalyticswebsite
Get rid of experiment .env var
Blue Mouse820529046aa3
diff --git a/web/app/routes/_index.tsx b/web/app/routes/_index.tsxindex dc4e39efd..70381f966 100644--- a/web/app/routes/_index.tsx+++ b/web/app/routes/_index.tsx@@ -47,10 +47,7 @@ import { LogoCloud } from '~/components/marketing/LogoCloud'import { ScrollReveal } from '~/components/marketing/ScrollReveal'import { WhySwitch } from '~/components/marketing/WhySwitch'import { Text } from '~/ui/Text'-import {- getExperimentVariant,- HERO_SIGNUP_EXPERIMENT_ID,-} from '~/utils/analytics.server'+import { getExperimentVariant } from '~/utils/analytics.server'import { trackCustom } from '~/utils/analytics'import { HERO_SIGNUP_EXPERIMENT } from '~/utils/experiments'@@ -81,7 +78,7 @@ export async function loader({ request }: LoaderFunctionArgs) {// visitor never sees the control arm flash before the variant swaps in.getExperimentVariant(request,- HERO_SIGNUP_EXPERIMENT_ID,+ 'hero-signup',HERO_SIGNUP_EXPERIMENT.control,),])diff --git a/web/app/utils/analytics.server.ts b/web/app/utils/analytics.server.tsindex 388bcca77..6b079e658 100644--- a/web/app/utils/analytics.server.ts+++ b/web/app/utils/analytics.server.ts@@ -12,15 +12,6 @@ const swetrix = new Swetrix(SWETRIX_PID, {const EXPERIMENT_FETCH_TIMEOUT_MS = 5_000-/**- * Hero signup CTA experiment (control: trial button, variant: website input).- * Create the experiment in the Swetrix dashboard, link a feature flag to it,- * then paste its UUID here or set the env var - an empty value keeps every- * visitor on the control arm.- */-export const HERO_SIGNUP_EXPERIMENT_ID =- process.env.HERO_SIGNUP_EXPERIMENT_ID || ''-export async function getExperimentVariant(request: Request,experimentId: string,