measurement-framework
Version:
Collection of Javascript code to implement a browser based measurement system for websites. It uses a cookie to store a users action on a webpage and let you map thoose actions to a particular state in the user journey.
15 lines (13 loc) • 410 B
JavaScript
import customTask from "./customTask"
/**
* Function takes a number of the dimension that will hold the Client ID.
* This will be added to every call to Google Analytics.
*
* @param clientIdDimension
*/
const clientIdSetter = function (clientIdDimension) {
customTask(function (model) {
model.set("dimension" + clientIdDimension, model.get("clientId"))
})
}
export default clientIdSetter