From c16e6d591f8c270368a3faff7475c8dfdf4695d0 Mon Sep 17 00:00:00 2001 From: Constance Okoghenun Date: Thu, 15 Feb 2018 13:12:47 +0100 Subject: [PATCH] Removed integrations webpack bundle tag --- app/assets/javascripts/dispatcher.js | 5 +++++ .../projects/services/edit}/index.js | 7 +++---- app/views/projects/services/_form.html.haml | 3 --- config/webpack.config.js | 1 - 4 files changed, 8 insertions(+), 8 deletions(-) rename app/assets/javascripts/{integrations => pages/projects/services/edit}/index.js (54%) diff --git a/app/assets/javascripts/dispatcher.js b/app/assets/javascripts/dispatcher.js index f8082c74943..e4288dc1317 100644 --- a/app/assets/javascripts/dispatcher.js +++ b/app/assets/javascripts/dispatcher.js @@ -224,6 +224,11 @@ var Dispatcher; .then(callDefault) .catch(fail); break; + case 'projects:services:edit': + import('./pages/projects/services/edit') + .then(callDefault) + .catch(fail); + break; case 'projects:snippets:edit': case 'projects:snippets:update': import('./pages/projects/snippets/edit') diff --git a/app/assets/javascripts/integrations/index.js b/app/assets/javascripts/pages/projects/services/edit/index.js similarity index 54% rename from app/assets/javascripts/integrations/index.js rename to app/assets/javascripts/pages/projects/services/edit/index.js index 10fe6bac0e8..434a7e44277 100644 --- a/app/assets/javascripts/integrations/index.js +++ b/app/assets/javascripts/pages/projects/services/edit/index.js @@ -1,7 +1,6 @@ -/* eslint-disable no-new */ -import IntegrationSettingsForm from './integration_settings_form'; +import IntegrationSettingsForm from '~/integrations/integration_settings_form'; -$(() => { +export default () => { const integrationSettingsForm = new IntegrationSettingsForm('.js-integration-settings-form'); integrationSettingsForm.init(); -}); +}; diff --git a/app/views/projects/services/_form.html.haml b/app/views/projects/services/_form.html.haml index 0808b28a9df..17e804d682b 100644 --- a/app/views/projects/services/_form.html.haml +++ b/app/views/projects/services/_form.html.haml @@ -1,6 +1,3 @@ -- content_for :page_specific_javascripts do - = webpack_bundle_tag('integrations') - .row.prepend-top-default.append-bottom-default .col-lg-3 %h4.prepend-top-0 diff --git a/config/webpack.config.js b/config/webpack.config.js index a4e6c64fce5..7e3050669a1 100644 --- a/config/webpack.config.js +++ b/config/webpack.config.js @@ -68,7 +68,6 @@ var config = { help: './help/help.js', how_to_merge: './how_to_merge.js', issue_show: './issue_show/index.js', - integrations: './integrations', job_details: './jobs/job_details_bundle.js', locale: './locale/index.js', main: './main.js',