vue-pdf-embed 是一个用于在 Vue.js 应用中嵌入和展示 PDF 文件的 Vue 组件。它允许你轻松地在 Vue 组件中加载和渲染 PDF 文件,并提供了一些基本的配置选项来控制 PDF 的展示方式。 vue-pdf-embed 在 vue2 中的安装步骤 要在Vue 2 项目中使用 vue-pdf-embed,你需要先通过 npm 或 yarn 将其安装到你的...
在Vue 2 中,你可以通过使用 iframe 或embed 标签来显示从 Base64 转换而来的 PDF 文件。以下是具体的实现方法: 1. 使用iframe 显示Base64 PDF 文件 你可以将 Base64 字符串直接嵌入到 iframe 的src 属性中。需要注意的是,Base64 字符串应当包含正确的前缀(如 data:application/pdf;base64,),以便浏览器正确解...
For Vue 2 support, install vue-pdf-embed@1 and refer to the v1 docs. Installation Depending on the environment, the package can be installed in one of the following ways: npm install vue-pdf-embed yarn add vue-pdf-embed <script src="https://unpkg.com/vue-pdf-embed"></script> Usage...
2 changes: 1 addition & 1 deletion 2 package.json Original file line numberDiff line numberDiff line change @@ -1,6 +1,6 @@ { "name": "@artesa/vue-pdf-embed", "version": "5.0.1", "version": "5.0.2-0", "description": "PDF embed component for Vue", "keywords": [ "vue...
PDF embed component for Vue 2 and Vue 3. Contribute to hrynko/vue-pdf-embed development by creating an account on GitHub.
npm install vue-pdf-embed yarn add vue-pdf-embed <script src="https://unpkg.com/vue-pdf-embed"></script> Usage <script setup> import VuePdfEmbed from 'vue-pdf-embed' // essential styles import 'vue-pdf-embed/dist/style/index.css' // optional styles import 'vue-pdf-embed/dist/style...
<script setup> import VuePdfEmbed from 'vue-pdf-embed' // optional styles import 'vue-pdf-embed/dist/styles/annotationLayer.css' import 'vue-pdf-embed/dist/styles/textLayer.css' // either URL, Base64, binary, or document proxy const pdfSource = '<PDF_URL>' </script> <template> <Vue...
PDF embed component for Vue 2 and Vue 3. Contribute to hrynko/vue-pdf-embed development by creating an account on GitHub.
<script setup> import VuePdfEmbed from 'vue-pdf-embed' // optional styles import 'vue-pdf-embed/dist/styles/annotationLayer.css' import 'vue-pdf-embed/dist/styles/textLayer.css' // either URL, Base64, binary, or document proxy const pdfSource = '<PDF_URL>' </script> <template> <Vue...
PDF embed component for Vue 2 and Vue 3. Contribute to hrynko/vue-pdf-embed development by creating an account on GitHub.