2019-03-01 09:51:54 -05:00
|
|
|
import Vue from 'vue';
|
|
|
|
import ErrorTrackingSettings from './components/app.vue';
|
|
|
|
import createStore from './store';
|
|
|
|
|
|
|
|
export default () => {
|
|
|
|
const formContainerEl = document.querySelector('.js-error-tracking-form');
|
|
|
|
const {
|
2021-09-15 17:11:12 -04:00
|
|
|
dataset: {
|
|
|
|
apiHost,
|
|
|
|
enabled,
|
|
|
|
integrated,
|
|
|
|
project,
|
|
|
|
token,
|
|
|
|
listProjectsEndpoint,
|
|
|
|
operationsSettingsEndpoint,
|
2021-09-23 18:34:10 -04:00
|
|
|
gitlabDsn,
|
2021-09-15 17:11:12 -04:00
|
|
|
},
|
2019-03-01 09:51:54 -05:00
|
|
|
} = formContainerEl;
|
|
|
|
|
|
|
|
return new Vue({
|
|
|
|
el: formContainerEl,
|
|
|
|
store: createStore(),
|
|
|
|
render(createElement) {
|
|
|
|
return createElement(ErrorTrackingSettings, {
|
|
|
|
props: {
|
|
|
|
initialApiHost: apiHost,
|
|
|
|
initialEnabled: enabled,
|
2021-09-15 17:11:12 -04:00
|
|
|
initialIntegrated: integrated,
|
2019-03-01 09:51:54 -05:00
|
|
|
initialProject: project,
|
|
|
|
initialToken: token,
|
|
|
|
listProjectsEndpoint,
|
|
|
|
operationsSettingsEndpoint,
|
2021-09-23 18:34:10 -04:00
|
|
|
gitlabDsn,
|
2019-03-01 09:51:54 -05:00
|
|
|
},
|
|
|
|
});
|
|
|
|
},
|
|
|
|
});
|
|
|
|
};
|