agrc / kitchen-sink

UGRC npm packages
https://gis.utah.gov/solutions/for-application-developers/
MIT License
4 stars 0 forks source link

create analytics tracking behavior #15

Open steveoh opened 8 years ago

steveoh commented 8 years ago

on basemap layer switching

steveoh commented 8 years ago

This article seems like a good reference for trying to use the window global if it is available.

Things I would like to be able to do:

  1. If analytics object is already in page use that analytic user id.
    • Gain insight on different types of users using things differently.
    • See all analytics for a widget event.
      • Will this require two tracking requests?
  2. Turn on and off event tracking
    • This could be a nested require with a boolean property we could edit.
    • This could be an api call that we manage with a database.
    • I'm open to other ideas.

Events I would like to capture with this widget

  1. Expanding the layer widget
    • This will tell us % of people who found the widget with their mouse based on total visits.
    • When a baselayer is changed.
      • Send new baselayer name.

Do we care about?