summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/monitoring/monitoring_bundle.js
blob: a9b608e44332f128cbe1194031ade6daa8f5f7ca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
import Vue from 'vue';
import Dashboard from './components/dashboard.vue';

export default () => {
  const el = document.querySelector('#prometheus-graphs');

  if (el && el.dataset) {
    // eslint-disable-next-line no-new
    new Vue({
      el,
      render(createElement) {
        return createElement(Dashboard, {
          props: el.dataset,
        });
      },
    });
  }
};