clicks.js: Plugin for clicktracking #13
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Using this plugin you can track every click a user makes on a page.
Configuring it is works as follows:
Using a seperate url allows to have a seperate server responsible for
handling a bigger load than your beacon server given that a typical
user will be clicking more than once on an average page.
You can use this plugin in one of two ways:
onbeforeunload : false
=> Sends click-tracking beacons immediatelyupon click_events happening
onbeforeunload : true
=> All Clicks that have been tracked aresent at once upon closing the page
Data sent to the beacon-server will contain the following:
element
: the name of the element that has been clicked(li,a,button,span etc)
id
: possibly set ids on the elementclass
: a list of all classes assigned to the elementdocument height/width
: the size of the documentviewport height/width
: the size of the browser windowInformation like this allows you (for example) to drill deeper into
what impact a change in the UI had(AB-Testing) or see which size most
users view your page which can allow for better optimized media-queries
for the formats used by the user base and heatmaps for the page as it
exists.