Skip to content

Commit e90f2be

Browse files
committed
removes fathom
1 parent f25ea73 commit e90f2be

10 files changed

Lines changed: 14 additions & 81 deletions

File tree

bun.lock

Lines changed: 1 addition & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@
3535
"class-variance-authority": "^0.7.1",
3636
"clsx": "^2.1.1",
3737
"cmdk": "^1.1.1",
38-
"fathom-client": "^3.7.2",
3938
"lucide-react": "^0.545.0",
4039
"next": "15.5.7",
4140
"next-themes": "^0.4.6",

public/witch/index.html

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -171,13 +171,6 @@
171171
(n.className += t + "touch");
172172
})(window, document);
173173
</script>
174-
<!-- Fathom - beautiful, simple website analytics disable - use the fathom component instead -->
175-
<!-- <script
176-
src="https://cdn.usefathom.com/script.js"
177-
data-site="ASGWDEGI"
178-
defer
179-
></script> -->
180-
<!-- / Fathom -->
181174
<link href="images/favicon.png" rel="shortcut icon" type="image/x-icon" />
182175
<link href="images/webclip.png" rel="apple-touch-icon" />
183176
<style>

src/app/layout.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { maziusDisplay, ebGaramond, ubuntuMono } from "@/lib/fonts";
33
import "./globals.css";
44
// import { ThemeProvider } from "next-themes";
55
import { Providers } from "@/providers/providers";
6-
import Fathom from "@/components/Fathom";
76
import VercelAnalytics from "@/components/VercelAnalytics";
87

98
export const metadata: Metadata = {
@@ -21,7 +20,6 @@ export default function RootLayout({
2120
<body
2221
className={`${maziusDisplay.variable} ${ebGaramond.variable} ${ubuntuMono.variable} antialiased`}
2322
>
24-
<Fathom />
2523
<VercelAnalytics />
2624
{/* <ThemeProvider
2725
attribute="class"

src/components/CohortHero.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
import Image from "next/image";
44
import { useState } from "react";
55
import { Input } from "./ui/input";
6-
import { trackEvent } from "fathom-client";
76
import { Button } from "./ui/button";
7+
import { analyticsEvents, trackAnalyticsEvent } from "@/lib/analytics";
88

99
const cohortImages = [
1010
"/images/cohort-image-1-bw.webp",
@@ -53,7 +53,9 @@ export default function CohortHero({ referral }: JoinUsProps) {
5353

5454
if (response.ok) {
5555
setSubmissionStatus("success");
56-
trackEvent("cohort-hero-email-signup");
56+
trackAnalyticsEvent(analyticsEvents.cohortHeroEmailSignup, {
57+
hasReferral: Boolean(referral),
58+
});
5759
setEmail("");
5860
} else {
5961
setSubmissionStatus("error");

src/components/Fathom.tsx

Lines changed: 0 additions & 55 deletions
This file was deleted.

src/components/HireUs.tsx

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ import {
4040
import Image from "next/image";
4141
import MultipleSelector, { type Option } from "./ui/multiselect";
4242
import { DISCORD_INVITE_URL } from "@/lib/data/constants";
43-
import { trackEvent } from "fathom-client";
4443
import { analyticsEvents, trackAnalyticsEvent } from "@/lib/analytics";
4544

4645
interface StepProps {
@@ -471,7 +470,6 @@ export default function HireUs() {
471470
setValidationErrors([]);
472471

473472
//tracking
474-
trackEvent("hire-us-submission");
475473
trackAnalyticsEvent(analyticsEvents.hireFormSubmitAttempt, {
476474
budget: formData.budget,
477475
servicesCount,
@@ -496,7 +494,6 @@ export default function HireUs() {
496494
setSubmissionStatus("success");
497495

498496
//tracking
499-
trackEvent("hire-us-submission");
500497
trackAnalyticsEvent(analyticsEvents.hireFormSubmitSuccess, {
501498
budget: formData.budget,
502499
servicesCount,
@@ -624,7 +621,6 @@ export default function HireUs() {
624621
component: <PersonalInfoStep form={form} />,
625622
validation: validatePersonalInfo,
626623
onStepComplete: () => {
627-
trackEvent("hire-us-step-1");
628624
trackAnalyticsEvent(analyticsEvents.hireFormStepCompleted, {
629625
step: "contact_info",
630626
stepNumber: 1,
@@ -638,7 +634,6 @@ export default function HireUs() {
638634
component: <ProjectDetailsStep form={form} />,
639635
validation: validateProjectDetails,
640636
onStepComplete: () => {
641-
trackEvent("hire-us-step-2");
642637
trackAnalyticsEvent(analyticsEvents.hireFormStepCompleted, {
643638
step: "project_details",
644639
stepNumber: 2,

src/components/JoinUs.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ import {
1515
} from "@/components/ui/form";
1616
import { joinUsFormSchema, type JoinUsFormData } from "@/lib/validation";
1717
import Image from "next/image";
18-
import { trackEvent } from "fathom-client";
1918
import { Button } from "./ui/button";
2019
import { analyticsEvents, trackAnalyticsEvent } from "@/lib/analytics";
2120

@@ -79,7 +78,6 @@ export default function JoinUs({ referral }: JoinUsProps) {
7978
setSubmissionStatus("success");
8079

8180
//tracking
82-
trackEvent("join-us-submission");
8381
trackAnalyticsEvent(analyticsEvents.joinSignupSuccess, {
8482
hasReferral: Boolean(referral),
8583
});

src/lib/analytics.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ export const analyticsEvents = {
1414
joinSignupAttempt: "Join Signup Attempt",
1515
joinSignupSuccess: "Join Signup Success",
1616
joinSignupError: "Join Signup Error",
17+
cohortHeroEmailSignup: "Cohort Hero Email Signup",
18+
witchTriggered: "Witch Triggered",
1719
} as const;
1820

1921
export function trackAnalyticsEvent(
@@ -28,4 +30,3 @@ export function trackAnalyticsEvent(
2830
}
2931
}
3032
}
31-

src/providers/providers.tsx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import { useEffect, useRef, useState } from "react";
44
import { useRouter } from "next/navigation";
5-
import { trackEvent } from "fathom-client";
5+
import { analyticsEvents, trackAnalyticsEvent } from "@/lib/analytics";
66

77
interface Drip {
88
id: number;
@@ -181,7 +181,9 @@ function useLegacy() {
181181
// Check if the trigger word was typed
182182
if (newTyped.includes(triggerWord.toLowerCase())) {
183183
setIsTriggered(true);
184-
trackEvent("witch");
184+
trackAnalyticsEvent(analyticsEvents.witchTriggered, {
185+
method: "keyboard",
186+
});
185187
setTypedKeys("");
186188

187189
// Wait for animation to complete before routing
@@ -204,7 +206,9 @@ function useLegacy() {
204206

205207
if (sequenceRef.current.join(",") === pattern.join(",")) {
206208
setIsTriggered(true);
207-
trackEvent("witch");
209+
trackAnalyticsEvent(analyticsEvents.witchTriggered, {
210+
method: "click_pattern",
211+
});
208212
sequenceRef.current = [];
209213

210214
setTimeout(() => {

0 commit comments

Comments
 (0)