debian-mirror-gitlab/app/assets/javascripts/blob/pdf/index.js

18 lines
330 B
JavaScript
Raw Normal View History

2017-08-17 22:00:37 +05:30
import Vue from 'vue';
2020-04-08 14:13:33 +05:30
import PdfViewer from './pdf_viewer.vue';
2017-08-17 22:00:37 +05:30
export default () => {
const el = document.getElementById('js-pdf-viewer');
return new Vue({
el,
2020-04-08 14:13:33 +05:30
render(createElement) {
return createElement(PdfViewer, {
props: {
pdf: el.dataset.endpoint,
},
});
2018-03-17 18:26:18 +05:30
},
2017-08-17 22:00:37 +05:30
});
};