debian-mirror-gitlab/app/assets/javascripts/logs/logs_tracking_helper.js

19 lines
458 B
JavaScript
Raw Normal View History

2020-06-23 00:09:42 +05:30
import Tracking from '~/tracking';
/**
* The value of 1 in count, means there was one action performed
* related to the tracked action, in either of the following categories
* 1. Refreshing the logs
* 2. Select an environment
* 3. Change the time range
* 4. Use the search bar
*/
2021-03-08 18:12:59 +05:30
const trackLogs = (label) =>
2020-06-23 00:09:42 +05:30
Tracking.event(document.body.dataset.page, 'logs_view', {
label,
property: 'count',
value: 1,
});
export default trackLogs;