# app-extension-qpdfviewer
**Repository Path**: lemon_engine/app-extension-qpdfviewer
## Basic Information
- **Project Name**: app-extension-qpdfviewer
- **Description**: No description available
- **Primary Language**: Unknown
- **License**: MIT
- **Default Branch**: master
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 0
- **Forks**: 0
- **Created**: 2021-04-29
- **Last Updated**: 2021-05-02
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
QPdfViewer (@quasar/qpdfviewer)
===


[]()
[]()
[](https://www.npmjs.com/package/@quasar/quasar-app-extension-qpdfviewer)
QPdfViewer is an `UI App Extension` for [Quasar Framework v1](https://v1.quasar-framework.org/). It will not work with legacy versions of Quasar Framework.
This work is currently in `beta` and there are expected changes while things get worked out. Your help with testing is greatly appreciated. Suggestions and PRs welcomed.
# Info
QPdfViewer allows you to have PDF in your web pages.
# Install
To add this App Extension to your Quasar application, run the following (in your Quasar app folder):
```
quasar ext add @quasar/qpdfviewer
```
# Uninstall
To remove this App Extension from your Quasar application, run the following (in your Quasar app folder):
```
quasar ext remove @quasar/qpdfviewer
```
# Describe
You can use `quasar describe QPdfViewer`
# Test Project
In **demo** folder of **app-extension-qpdfviewer**.
# Demo
Can be found [here](https://quasarframework.github.io/app-extension-qpdfviewer)
# Example Code
Be sure to check out the Test Project for more examples.
```html
or
```
Using blob data (for `type="html5"` only):
```js
fetchPDF (payload) {
this.$axios.post('/my/url/to/pdf', payload, { responseType: 'blob' }).then(res => {
// create the blob
const blob = new Blob([res.data], { type: res.data.type })
// set reactive variable
pdfSrc = window.URL.createObjectURL(blob)
}).catch(err => {
this.$q.notify({
message: 'Error downloading PDF',
type: 'negative',
textColor: 'white',
color: 'negative',
icon: 'error',
closeBtn: 'close',
position: 'top'
})
})
}
```
---
NOTE:
QPdfviewer now has support for native HTML5 PDF viewer and for PDFJS. Use `type="html5"` or `type="pdfjs"`. If you previously has this app extension, and want to use the pdfjs, you will need to re-install it. An update will not get the PDFJS for you. If you update, you can run `quasar ext invoke @quasar/qpdfviewer` instead of re-installing.
---
NOTE:
QPdfviewer uses the `