@vibe_cms/analytics
v0.1.0
Published
Privacy-respecting, self-hosted traffic analytics for VibeCMS: tracking pixel, event recording, and dashboard aggregation.
Readme
@vibe_cms/analytics
Privacy-respecting, self-hosted traffic analytics for VibeCMS.
Provides a tracking snippet, a pixel endpoint contract, event recording, and daily aggregation. It never stores raw IPs — visitors are hashed with a salt and a coarse time bucket so uniques are counted without identifying individuals.
import { hashVisitor, extractIp, dayKey } from '@vibe_cms/analytics'
const ip = extractIp(request)
const hash = hashVisitor(ip, config.analytics.ipHashSalt)The public site injects the tracking snippet (TRACKING_PIXEL_SNIPPET) and the
server records events. See docs/analytics.md for the
full pipeline and dashboard queries.
