Developers
The mParticle SDK lets you track “errors” and “exceptions”. These two terms have slightly different meanings:
As with other events, extra attributes can be passed via the Event Info object.
mParticle.logError('Login failed');
The SDK can be configured to intercept calls to the JavaScript error console in Chrome and Firefox, and pass information on to mParticle:
(function () {
var log = console.log;
console.log = function () {
var args = Array.prototype.slice.call(arguments);
mParticle.logError(args.toString())
log.apply(this, Array.prototype.slice.call(arguments));
};
}());
Was this page helpful?