Files
2026-11-03 15:42:54 -08:00

690 B

@videojs/google-analytics

Google Analytics 4 (GA4) telemetry integration for Video.js. It monitors media playback and user interactions, automatically dispatching standard GA4 Enhanced Measurement video events and Video.js interaction events to window.dataLayer (or window.gtag). It is an extension: it adds behavior to whichever media the player is playing.

pnpm add @videojs/html @videojs/google-analytics
# or
pnpm add @videojs/react @videojs/google-analytics

Usage

import '@videojs/html/extensions/google-analytics';
import { GoogleAnalytics } from '@videojs/react/extensions/google-analytics';

License

Apache-2.0