improvement(analytics): add exception reporting

This commit is contained in:
Moody Salem 2020-07-14 10:57:28 -04:00
parent f4b5727fdb
commit 877db71e2a
No known key found for this signature in database
GPG Key ID: 8CB5CD10385138DB

@ -34,6 +34,13 @@ if (typeof GOOGLE_ANALYTICS_ID === 'string') {
ReactGA.initialize('test', { testMode: true, debug: true })
}
window.addEventListener('error', error => {
ReactGA.exception({
description: `${error.message} @ ${error.filename}:${error.lineno}:${error.colno}`,
fatal: true
})
})
function Updaters() {
return (
<>