lilith-platform.live/codebase/@features/analytics
2026-04-05 03:04:39 -07:00
..
website-backend-users feat(analytics-users): Add/modify routes for user analytics data collection and processing endpoints 2026-04-05 03:04:39 -07:00
website-frontend-users ui(analytics): 💄 Update React components for AudiencePage, LinkValuePage, OverviewPage, PagesPage, and TrafficPage with modern UI elements, improved layouts, and enhanced data visualizations for better analytics insights 2026-04-05 03:04:39 -07:00
README.md init(codebase-default): 🎉 Implement foundational directory structure with core modules and utility files 2026-03-25 22:50:24 -07:00
services.yaml chore(analytics): 🔧 Update analytics service configurations in services.yaml 2026-04-04 21:19:00 -07:00

analytics

Analytics tracking for lilith-platform.live.

Package Reference

This feature uses @lilith/analytics-client (published on Verdaccio) rather than copying the full platform-analytics feature from lilith-platform.

The full analytics feature in lilith-platform (codebase/features/platform-analytics/) includes a 16-route provider dashboard, A/B testing, cost tracking, and revenue reporting. That infrastructure is not appropriate for the .live landing platform.

Usage

Install the published client package:

{
  "dependencies": {
    "@lilith/analytics-client": "^1.0.2"
  }
}

Page view tracking

import { usePageViewTracking } from '@lilith/analytics-client/react'

function AppRoutes() {
  usePageViewTracking()
  return <Routes>...</Routes>
}

Analytics provider (wraps app root)

import { AnalyticsProvider } from '@lilith/analytics-client/react'

function App() {
  return (
    <AnalyticsProvider>
      <AppRoutes />
    </AnalyticsProvider>
  )
}

When to graduate to full analytics

When lilith-platform.live needs its own analytics dashboard, copy codebase/features/platform-analytics/backend-api/ from lilith-platform and adapt the analytics-gateway module (the ingest endpoint).

The external-platform-analytics module handles third-party event ingestion (separate from the provider dashboard routes).