Commit Graph
11 Commits
Author SHA1 Message Date
nerandClaude Opus 5 d67a0d4df6 feat(analytics): self-hosted openpanel with a typed event catalogue
Replaces Vercel Analytics with OpenPanel, driven entirely by env vars so the
whole layer is inert until NEXT_PUBLIC_OPENPANEL_CLIENT_ID is set.

Zero initial load cost. next/script emits a rel=preload even on lazyOnload,
which pulls the sdk during the first paint, so the component skips it: it
inlines the 416 byte official stub (window.op queues calls immediately) and
appends the real script itself on window load plus requestIdleCallback. The
built html carries no preload and no script src for the analytics host.

Events live in one typed catalogue (lib/analytics/events.ts) and track() is
keyed to it, so a wrong name or payload is a type error rather than a silent
bad row. Emitters sit in the hooks that already own the behaviour instead of
being sprinkled through components:

- useShowState covers every favourite and watchlist toggle
- useInfiniteList covers pagination for all six lists
- useTorrents covers all three providers
- Preview, Person and useSearch use a shared useTrackOnce hook

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-14 12:08:16 +03:00
ner e5c44fe359 feat: static generation 2024-11-04 12:47:15 +02:00
ner dfdfb79169 fix: SITE_URL 2024-10-28 17:20:05 +02:00
ner 5cbf93b3b8 refactoring: server actions data fetching -> api routes 2024-10-26 21:33:39 +03:00
ner 38aebcbe28 refactoring: improvements for lighthouse 2024-10-21 15:35:08 +03:00
ner ebf599eed6 refactor: clean code and remove unnecessary dependencies 2024-09-30 18:54:13 +03:00
ner c6d306cb7b fix: torrent size 2024-03-19 20:15:42 +02:00
ner 03cfacf91c refactoring: upgrade nextjs; api => server actions 2024-01-06 12:55:11 +02:00
ner 8bff4d6d80 feat: added torrents and similar for every movie 2023-08-18 12:36:10 +03:00
ner 89e76f5df6 feat: added favorites page 2023-08-09 18:43:48 +03:00
ner 3c1050898e feat: Initialize project 2023-08-05 12:28:04 +03:00