ga.js中旧的_setCustomVar
是否与analytics.js中的任何方法有直接对应关系?
Yes, although it depends on your needs. It'll be one of the following:
ga('set', 'dimensionX', 'foobar');
// OR
ga('set', 'metricY', 501);
Replace X or Y with the number... remember you now have 20 of each for the free version. Quick and dirty difference: dimensions are the words (describes what it is) and metrics are the numbers of reports (how many / value).
Also, I created a migration guide that covers most of the methods from GA -> UA. It should help you out!
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.