pulsar-analytics
TypeScript icon, indicating that this package has built-in type declarations

32.0.0 • Public • Published

Pulsar-Analytics

Player agnostic analytics implementation of Twitch video metrics.

Supported Events

  • Minute Watched
  • Video Play
  • Buffer Empty
  • Buffer Refill
  • Video Error
  • Video Ended

This package will attach primitive player information, it is up to the consumer to attach higher level environment, user, and content specific tracking fields. See src/events for the full implementation details.

Usage

yarn add pulsar-analytics
import { subscribeVideoAnalytics } from 'pulsar-analytics';

// Calling this will cleanup any listeners that were created
const unSubscribeVideoAnalytics = subscribeVideoAnalytics({
  backend: 'native',
  onTrackingEvent: (playerEvent) => {
    /*...*/
  },
  timeSinceLoadStart: Date.now(),
  video: videoElement,
});

/pulsar-analytics/

    Package Sidebar

    Install

    npm i pulsar-analytics

    Weekly Downloads

    0

    Version

    32.0.0

    License

    UNLICENSED

    Unpacked Size

    33.6 kB

    Total Files

    42

    Last publish

    Collaborators

    • frgjdhskxjogu