debian-mirror-gitlab/app/assets/javascripts/ide/stores/extend.js
2020-06-23 00:09:42 +05:30

14 lines
407 B
JavaScript

import terminal from './plugins/terminal';
import terminalSync from './plugins/terminal_sync';
const plugins = () => [
terminal,
...(gon.features && gon.features.buildServiceProxy ? [terminalSync] : []),
];
export default (store, el) => {
// plugins is actually an array of plugin factories, so we have to create first then call
plugins().forEach(plugin => plugin(el)(store));
return store;
};