chore: Add error logging config on the vue package (#1670)
This commit is contained in:
@@ -28,9 +28,14 @@ import {
|
||||
verifyServiceWorkerExistence,
|
||||
registerSubscription,
|
||||
} from '../dashboard/helper/pushHelper';
|
||||
import * as Sentry from '@sentry/vue';
|
||||
|
||||
Vue.config.env = process.env;
|
||||
|
||||
if (window.errorLoggingConfig) {
|
||||
Sentry.init({ Vue: Vue, dsn: window.errorLoggingConfig });
|
||||
}
|
||||
|
||||
Vue.use(VueRouter);
|
||||
Vue.use(VueI18n);
|
||||
Vue.use(WootUiKit);
|
||||
|
||||
@@ -42,6 +42,7 @@
|
||||
selectedLocale: '<%= I18n.locale %>'
|
||||
}
|
||||
window.globalConfig = <%= raw @global_config.to_json %>
|
||||
window.errorLoggingConfig = '<%= ENV.fetch('SENTRY_DSN', '')%>'
|
||||
</script>
|
||||
<%= javascript_pack_tag 'application' %>
|
||||
<%= stylesheet_pack_tag 'application' %>
|
||||
|
||||
Reference in New Issue
Block a user