Giter VIP home page Giter VIP logo

mixpanel_hax's Introduction

mixpanel_hax

for testing out mixpanel stuffs

read me

  • mixpanel does not recommend this approach.
  • released under MIT license.
  • i make no warranty as to the fitness of this code.
  • [insert other obgligatory preamble here later]

status

the code works in a dev environment with manually passed URL params. next step is to set live on the web, set up corresponding test campaign, view, and project in adwords, GA, and mixpanel, respectively, and see if everything works with ad clicks containing non-utm-prefixed destination URL params as well as dynamically inserted VT params.

background

i'm testing this out b/c i want to find a way to get adwords, GA, and mixpanel to play nicely togetner. what do i mean by this?

if you've set up auto-tagging for adwords and GA you get a lot of useful data for free through gclid. but 3rd party apps can't use gclid data, so if you want your 3rd party app to track utm_source, for example, you have to find another way of passing it in the URL.

manually tagging destination URLs with utm parameters allows 3rd party apps to "see" these data, but google don't recommend using auto-tagging and manually setting utm-prefixed params because it can cause things to get "wonky" in GA.

we could use non-utm-prefixed params in destination URLs and register corresponding properties in mixpanel, but out of the box there's no way i know of to tell mixpanel, "hey, aw_source is the same thing as utm_source, so let's just use that in our reporting, mmkay?"

an aside: like us you may want to automate tracking of dynamic performance-related data such as search keywords, search ad position, display URL (etc.). see goog's documentation on ValueTrack and read the test code here to see how to implement.

solution

to note: mixpanel advises against forking their code and self-hosting (for some good reasons) so we'll look into taking this functionality out and placing it in our code.

to see how we're attempting this take a look at the diff between the first and third commits. the first commit is mixpanel's unmodified code and the third commit includes comments about functionality, ideas for extending the code, and a few more params that could be interesting.

comments/suggestions welcome!

mixpanel_hax's People

Contributors

charle5 avatar

Stargazers

Dave Clark avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.