diff options
author | Fatih Acet <acetfatih@gmail.com> | 2019-03-04 14:24:35 +0300 |
---|---|---|
committer | Fatih Acet <acetfatih@gmail.com> | 2019-03-04 14:24:35 +0300 |
commit | 86054032b9cf164e4d663c0e05f2bc6970121ab8 (patch) | |
tree | 7b147c2c2e94a3c28b4ee681602fe746e65db055 /app | |
parent | f950aa900237818c98ceb83d794188cea21ae88d (diff) | |
parent | d64ec5df34d6bbc1db1562e2cc5eb9c77c09fe06 (diff) |
Merge branch 'winh-import_projects_table_spec' into 'master'
Use factory method for import_projects store
Closes gitlab-ee#10062
See merge request gitlab-org/gitlab-ce!25646
Diffstat (limited to 'app')
-rw-r--r-- | app/assets/javascripts/import_projects/index.js | 3 | ||||
-rw-r--r-- | app/assets/javascripts/import_projects/store/index.js | 13 |
2 files changed, 9 insertions, 7 deletions
diff --git a/app/assets/javascripts/import_projects/index.js b/app/assets/javascripts/import_projects/index.js index 5c77484aee1..2d99d716609 100644 --- a/app/assets/javascripts/import_projects/index.js +++ b/app/assets/javascripts/import_projects/index.js @@ -3,7 +3,7 @@ import { mapActions } from 'vuex'; import Translate from '../vue_shared/translate'; import ImportProjectsTable from './components/import_projects_table.vue'; import { parseBoolean } from '../lib/utils/common_utils'; -import store from './store'; +import createStore from './store'; Vue.use(Translate); @@ -20,6 +20,7 @@ export default function mountImportProjectsTable(mountElement) { ciCdOnly, } = mountElement.dataset; + const store = createStore(); return new Vue({ el: mountElement, store, diff --git a/app/assets/javascripts/import_projects/store/index.js b/app/assets/javascripts/import_projects/store/index.js index 6ac9bfd8189..f666e2ebf33 100644 --- a/app/assets/javascripts/import_projects/store/index.js +++ b/app/assets/javascripts/import_projects/store/index.js @@ -7,9 +7,10 @@ import mutations from './mutations'; Vue.use(Vuex); -export default new Vuex.Store({ - state: state(), - actions, - mutations, - getters, -}); +export default () => + new Vuex.Store({ + state: state(), + actions, + mutations, + getters, + }); |