npm mixpanel-browser 2.48.0
Configurable API endpoints, miscellaneous updates and fixes

latest releases: 2.51.0, 2.50.0, 2.49.0...
10 months ago

API endpoint routes can now be configured individually, so you can rename /track, /engage, and /groups HTTP endpoints arbitrarily. Configure with the api_routes option:

mixpanel.init(`my token`, {
  api_host: `https://my-proxy.example.com`,
  api_routes: {
    track: `foo/`,
    engage: `bar/`,
    groups: `baz/`,
  },
));

In the above example, event-tracking requests will go to https://my-proxy.example.com/foo/, user profile updates to https://my-proxy.example.com/bar/, etc.

Other fixes:

  • Event properties object passed to mixpanel.track() will no longer be mutated
  • Super properties are now reloaded from persistence when making every tracking call (i.e., kept fresh when another tab/window in the same browser has updated them)
  • Extra failsafe behavior for trying to clear queued requests when localStorage doesn't work on startup, e.g., when localStorage is full so writes fail
  • Block Chrome-Lighthouse user agent
  • Fix for error in add_group() when adding a new group to an existing list

Don't miss a new mixpanel-browser release

NewReleases is sending notifications on new releases.