debian-mirror-gitlab/app/assets/javascripts/clusters/forms/show/index.js

31 lines
786 B
JavaScript
Raw Normal View History

2020-10-24 23:57:45 +05:30
import Vue from 'vue';
2021-04-29 21:17:54 +05:30
import dirtySubmitFactory from '~/dirty_submit/dirty_submit_factory';
2020-10-24 23:57:45 +05:30
import IntegrationForm from '../components/integration_form.vue';
import { createStore } from '../stores';
export default () => {
2021-04-29 21:17:54 +05:30
dirtySubmitFactory(document.querySelectorAll('.js-cluster-integrations-form'));
const entryPoint = document.querySelector('#js-cluster-details-form');
2020-10-24 23:57:45 +05:30
if (!entryPoint) {
return;
}
const { autoDevopsHelpPath, externalEndpointHelpPath } = entryPoint.dataset;
// eslint-disable-next-line no-new
new Vue({
el: entryPoint,
store: createStore(entryPoint.dataset),
provide: {
autoDevopsHelpPath,
externalEndpointHelpPath,
},
render(createElement) {
return createElement(IntegrationForm, {});
},
});
};