I am trying to implement the pdfjs express plus demo on vue3, with the actual version 8.7.0 but when i use the VUEJS demo and update the package, it keeps showing this errors:
File extension pdf" is not supported. Please see Apryse Documentation | Documentation for a full list of file formats supported by WebViewer
i am not changing anything, the code is the same.
<template>
<div>
<label for="file_upload">Choose A file</label>
<input type="file" id="file_upload" name="file_upload" accept=".pdf" />
<div ref="viewer"></div>
</div>
</template>
<script>
/* eslint-disable */
import WebViewer from '@pdftron/pdfjs-express';
export default {
name: 'WebViewer',
props: {
path: String,
url: String,
},
mounted: function() {
WebViewer(
{
path: this.path,
initialDoc: this.url, // replace with your own PDF file
},
this.$refs.viewer
).then((instance) => {
//console.log(instance)
const input = document.getElementById('file_upload');
input.addEventListener('change', () => {
// Get the file from the input
const file = input.files[0];
instance.loadDocument(file, { filename: file.name });
});
});
},
};
</script>
Its there a way to update the pdfjs version on the try free demo, because i need to know if i can achieve what i need to buy the license