Documentation ¶
Overview ¶
Package analytics provides functions to send analytics to analytics stores such as Google Analytics.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GoogleAnalyticsHeader ¶
GoogleAnalyticsHeader returns the header to use in the app.Handler.RawHeader field to initialize Google Analytics.
Types ¶
type Backend ¶
type Backend interface { // Links your users, and their actions, to a recognizable userID and traits. Identify(userID string, traits map[string]interface{}) // Record actions your users perform. Track(event string, properties map[string]interface{}) // Records page views on your website, along with optional extra information // about the page viewed by the user. Page(name string, properties map[string]interface{}) }
Backend is the interface that describes an analytics backend that sends analytics for a defined provider.
func NewGoogleAnalytics ¶
func NewGoogleAnalytics() Backend
Click to show internal directories.
Click to hide internal directories.