mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-06 11:23:48 -05:00
Uses the new javascript event tracking stuff so that we can see what errors people are getting when they upload spreadsheets.
23 lines
331 B
JavaScript
23 lines
331 B
JavaScript
(function(Modules) {
|
|
"use strict";
|
|
|
|
Modules.TrackError = function() {
|
|
|
|
this.start = function(component) {
|
|
|
|
if (!ga) return;
|
|
|
|
ga(
|
|
'send',
|
|
'event',
|
|
'Error',
|
|
$(component).data('error-type'),
|
|
$(component).data('error-label')
|
|
);
|
|
|
|
};
|
|
|
|
};
|
|
|
|
})(window.GOVUK.Modules);
|