okgrow / analytics

UNMAINTAINED! - Complete Google Analytics, Mixpanel, KISSmetrics (and more) integration for Meteor
https://atmospherejs.com/okgrow/analytics
MIT License
213 stars 61 forks source link

Mixpanel Clarification #178

Closed emilbruckner closed 7 years ago

emilbruckner commented 7 years ago

All data I see in Mixpanel is "Loaded a page" Is this the expected behaviour? How would I setup tracking people?

Thanks

townmulti commented 7 years ago

+1 on this! Also for Mixpanel clarification, when loading data in a pagination event, I'm getting a GET http status code 414 (URI too Large) error in the console. Is there some way to truncate what's being sent to Mixpanel?

cfnelson commented 7 years ago

@emilbruckner Only pages are tracked by default. If you have meteors accounts package installed then this package will track signing in/out by calling identify. If you want to track custom events you will need to set that up yourself with analytics.track().

For more details on specifically mixpanel I would take a look at the doc's from segment.io for the mixpanel integration. Take a look at their examples for identify and track as well.

cfnelson commented 7 years ago

@townmulti How long is your URI? If the above error is for analytics.page() segment.io's analytics.js library automatically collects/sends the title, path, url, referrer, and search. You would have to override the properties automatically collected for the specific page causing you issues by hardcoding their values. Example below

analytics.page('MyPaginationPage', {
  title: 'Doc title for page',
  url: 'set my short url here',
  path: '/my-short-path',
});

Take a read of segment.io's specs for page here and also their docs for the page event here.