gitlab-org--gitlab-foss/app/assets/javascripts/ide/stores/index.js
Paul Slaughter adbf6149cf Keep IDE RightPane views alive
**Why?**
- This is needed for the Web Terminal feature.
  https://gitlab.com/gitlab-org/gitlab-ee/issues/5426

**Notes:**
- Introduces a `pane` Vuex module.
- Some views should not be kept alive (i.e. job details).
  This is why a `keepAlive` flag was introduced for views.
2018-09-28 15:03:39 -05:00

32 lines
812 B
JavaScript

import Vue from 'vue';
import Vuex from 'vuex';
import state from './state';
import * as actions from './actions';
import * as getters from './getters';
import mutations from './mutations';
import commitModule from './modules/commit';
import pipelines from './modules/pipelines';
import mergeRequests from './modules/merge_requests';
import branches from './modules/branches';
import fileTemplates from './modules/file_templates';
import paneModule from './modules/pane';
Vue.use(Vuex);
export const createStore = () =>
new Vuex.Store({
state: state(),
actions,
mutations,
getters,
modules: {
commit: commitModule,
pipelines,
mergeRequests,
branches,
fileTemplates: fileTemplates(),
rightPane: paneModule(),
},
});
export default createStore();