debian-mirror-gitlab/app/assets/javascripts/blob/pdf/index.js
2020-04-08 14:13:33 +05:30

17 lines
330 B
JavaScript

import Vue from 'vue';
import PdfViewer from './pdf_viewer.vue';
export default () => {
const el = document.getElementById('js-pdf-viewer');
return new Vue({
el,
render(createElement) {
return createElement(PdfViewer, {
props: {
pdf: el.dataset.endpoint,
},
});
},
});
};