Commit 8002f99e authored by Olena Horal-Koretska's avatar Olena Horal-Koretska

Unwrap handlers from DOMContentLoaded in Monitor:Health pages

parent 67c136a6
import AlertDetails from '~/alert_management/details';
document.addEventListener('DOMContentLoaded', () => {
AlertDetails('#js-alert_details');
});
AlertDetails('#js-alert_details');
import AlertManagementList from '~/alert_management/list';
document.addEventListener('DOMContentLoaded', () => {
AlertManagementList();
});
AlertManagementList();
import ErrorTrackingDetails from '~/error_tracking/details';
document.addEventListener('DOMContentLoaded', () => {
ErrorTrackingDetails();
});
ErrorTrackingDetails();
import ErrorTrackingList from '~/error_tracking/list';
document.addEventListener('DOMContentLoaded', () => {
ErrorTrackingList();
});
ErrorTrackingList();
import IncidentsList from '~/incidents/list';
document.addEventListener('DOMContentLoaded', () => {
IncidentsList();
});
IncidentsList();
......@@ -2,10 +2,8 @@ import initSidebarBundle from '~/sidebar/sidebar_bundle';
import initRelatedIssues from '~/related_issues';
import initShow from '../../issues/show';
document.addEventListener('DOMContentLoaded', () => {
initShow();
if (!gon.features?.vueIssuableSidebar) {
initSidebarBundle();
}
initRelatedIssues();
});
initShow();
if (!gon.features?.vueIssuableSidebar) {
initSidebarBundle();
}
initRelatedIssues();
import monitoringApp from '~/monitoring/monitoring_app';
document.addEventListener('DOMContentLoaded', monitoringApp);
monitoringApp();
import PersistentUserCallout from '~/persistent_user_callout';
document.addEventListener('DOMContentLoaded', () => {
const callout = document.querySelector('.js-webhooks-moved-alert');
PersistentUserCallout.factory(callout);
});
const callout = document.querySelector('.js-webhooks-moved-alert');
PersistentUserCallout.factory(callout);
......@@ -5,13 +5,11 @@ import mountGrafanaIntegration from '~/grafana_integration';
import initSettingsPanels from '~/settings_panels';
import initIncidentsSettings from '~/incidents_settings';
document.addEventListener('DOMContentLoaded', () => {
initIncidentsSettings();
mountErrorTrackingForm();
mountOperationSettings();
mountGrafanaIntegration();
if (!IS_EE) {
initSettingsPanels();
}
mountAlertsSettings(document.querySelector('.js-alerts-settings'));
});
initIncidentsSettings();
mountErrorTrackingForm();
mountOperationSettings();
mountGrafanaIntegration();
if (!IS_EE) {
initSettingsPanels();
}
mountAlertsSettings(document.querySelector('.js-alerts-settings'));
......@@ -2,7 +2,5 @@ import '~/pages/projects/settings/operations/show/index';
import mountStatusPageForm from 'ee/status_page_settings';
import initSettingsPanels from '~/settings_panels';
document.addEventListener('DOMContentLoaded', () => {
mountStatusPageForm();
initSettingsPanels();
});
mountStatusPageForm();
initSettingsPanels();
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment