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

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/assets/javascripts/observability/index.js')
-rw-r--r--app/assets/javascripts/observability/index.js28
1 files changed, 28 insertions, 0 deletions
diff --git a/app/assets/javascripts/observability/index.js b/app/assets/javascripts/observability/index.js
new file mode 100644
index 00000000000..cd342ebee3e
--- /dev/null
+++ b/app/assets/javascripts/observability/index.js
@@ -0,0 +1,28 @@
+import Vue from 'vue';
+import VueRouter from 'vue-router';
+
+import ObservabilityApp from './components/observability_app.vue';
+
+Vue.use(VueRouter);
+
+export default () => {
+ const el = document.getElementById('js-observability-app');
+
+ if (!el) return false;
+
+ const router = new VueRouter({
+ mode: 'history',
+ });
+
+ return new Vue({
+ el,
+ router,
+ render(h) {
+ return h(ObservabilityApp, {
+ props: {
+ observabilityIframeSrc: el.dataset.observabilityIframeSrc,
+ },
+ });
+ },
+ });
+};