diff --git a/ee/app/assets/javascripts/pages/security/dashboard/show/index.js b/ee/app/assets/javascripts/pages/security/dashboard/show/index.js index f8414202b0c1cbd743d1b16ffc1a59135443b35e..329268e68250a0b36cffe40bec811a58b4aea51c 100644 --- a/ee/app/assets/javascripts/pages/security/dashboard/show/index.js +++ b/ee/app/assets/javascripts/pages/security/dashboard/show/index.js @@ -1,6 +1,4 @@ import initSecurityCharts from 'ee/security_dashboard/security_charts_init'; import { DASHBOARD_TYPES } from 'ee/security_dashboard/store/constants'; -document.addEventListener('DOMContentLoaded', () => { - initSecurityCharts(document.getElementById('js-security'), DASHBOARD_TYPES.INSTANCE); -}); +initSecurityCharts(document.getElementById('js-security'), DASHBOARD_TYPES.INSTANCE); diff --git a/ee/changelogs/unreleased/defer-optimization-for-security-dashboard-show.yml b/ee/changelogs/unreleased/defer-optimization-for-security-dashboard-show.yml new file mode 100644 index 0000000000000000000000000000000000000000..64bb13b1b6d94827991f74cda6ba047d81ecdc17 --- /dev/null +++ b/ee/changelogs/unreleased/defer-optimization-for-security-dashboard-show.yml @@ -0,0 +1,5 @@ +--- +title: Removed DOMContentLoaded Eventlistener from ee/app/assets/javascripts/pages/security/dashboard/show/index.js +merge_request: 47515 +author: +type: changed