Welcome to mirror list, hosted at ThFree Co, Russian Federation.

index.js « ci_variable_list « javascripts « assets « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 58501b216c1082d072661deebea7b8945d60f24b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import Vue from 'vue';
import CiVariableSettings from './components/ci_variable_settings.vue';
import createStore from './store';
import { parseBoolean } from '~/lib/utils/common_utils';

export default () => {
  const el = document.getElementById('js-ci-project-variables');
  const { endpoint, projectId, group, maskableRegex } = el.dataset;
  const isGroup = parseBoolean(group);

  const store = createStore({
    endpoint,
    projectId,
    isGroup,
    maskableRegex,
  });

  return new Vue({
    el,
    store,
    render(createElement) {
      return createElement(CiVariableSettings);
    },
  });
};