diff options
author | Mike Greiling <mike@pixelcog.com> | 2018-02-02 16:48:17 -0600 |
---|---|---|
committer | Mike Greiling <mike@pixelcog.com> | 2018-02-16 12:47:22 -0600 |
commit | 8c92330c5074ad2cc723a9bbd56d80d44b52afd9 (patch) | |
tree | f5b7dccec2706aedbfa7731f311a4f5daea40a72 /app | |
parent | bba4126311257628bb136de6b7a1d83a262bbd8e (diff) | |
download | gitlab-ce-8c92330c5074ad2cc723a9bbd56d80d44b52afd9.tar.gz |
migrate projects:branches:new to static bundle
Diffstat (limited to 'app')
-rw-r--r-- | app/assets/javascripts/dispatcher.js | 10 | ||||
-rw-r--r-- | app/assets/javascripts/pages/projects/branches/new/index.js | 4 |
2 files changed, 3 insertions, 11 deletions
diff --git a/app/assets/javascripts/dispatcher.js b/app/assets/javascripts/dispatcher.js index 6cc71e03855..1566084f2d8 100644 --- a/app/assets/javascripts/dispatcher.js +++ b/app/assets/javascripts/dispatcher.js @@ -48,16 +48,6 @@ var Dispatcher; case 'projects:issues:show': shortcut_handler = true; break; - case 'projects:branches:new': - import('./pages/projects/branches/new') - .then(callDefault) - .catch(fail); - break; - case 'projects:branches:create': - import('./pages/projects/branches/new') - .then(callDefault) - .catch(fail); - break; case 'projects:branches:index': import('./pages/projects/branches/index') .then(callDefault) diff --git a/app/assets/javascripts/pages/projects/branches/new/index.js b/app/assets/javascripts/pages/projects/branches/new/index.js index ae5e033e97e..d32d5c6cb29 100644 --- a/app/assets/javascripts/pages/projects/branches/new/index.js +++ b/app/assets/javascripts/pages/projects/branches/new/index.js @@ -1,3 +1,5 @@ import NewBranchForm from '~/new_branch_form'; -export default () => new NewBranchForm($('.js-create-branch-form'), JSON.parse(document.getElementById('availableRefs').innerHTML)); +document.addEventListener('DOMContentLoaded', () => ( + new NewBranchForm($('.js-create-branch-form'), JSON.parse(document.getElementById('availableRefs').innerHTML)) +)); |