@videojs/google-analytics
v10.3.0
Published
Google Analytics 4 (GA4) telemetry integration for Video.js
Readme
@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-analyticsUsage
import '@videojs/html/extensions/google-analytics';import { GoogleAnalytics } from '@videojs/react/extensions/google-analytics';