try to use third party plugin in custom code
code for wwSection.vue:
<template>
<div class="my-section" id="app">
<WebViewer :path="`${publicPath}`" url="https://pdftron.s3.amazonaws.com/downloads/pl/webviewer-demo.pdf"/>
</div>
</template>
<script>
import WebViewer from './components/WebViewer.vue'
export default {
name: 'app',
components: {
WebViewer
},
data () {
return {
publicPath: `/public/pdfjsexpress/`
}
}
}
</script>
<style lang="scss" scoped>
.my-section {
display: flex;
flex-direction: column;
align-items: center;
min-height: 200px;
h1 {
font-size: 32px;
}
p {
margin-top: 12px;
}
}
</style>
ww-config.js
export default {
editor: {
label: {
en: "PDF Viewer",
},
},
properties: {
pdfUrl: {
label: {
en: "PDF URL",
},
type: "String",
defaultValue: "",
},
}
};