VuePDF is a Vue 3 component for pdf.js that allows you to flexibly display PDF pages within your project.
npm i @tato30/vue-pdf
yarn add @tato30/vue-pdf
<script setup>
import { VuePDF, usePDF } from '@tato30/vue-pdf'
const { pdf, pages, info } = usePDF('document.pdf')
console.log(`Document has ${pages} pages`)
console.log(`Document info: ${info}`)
</script>
<template>
<VuePDF :pdf="pdf" />
</template>