A simple PDF viewer.
Remark This repository is the replacement for madmas/nativescript-pdf-view which was a fork of the original by Merott and will be used with his consent to provide further maintenance of this NativeScript plugin.
It serves minimal PDF view implementation that does only one thing, and that is to display PDF files in the simplest way possible. It conveniently uses the iOS WKWebView
, and for Android it uses AndroidPdfViewer
.
npm install @nativescript/pdf
<Page
xmlns="http://schemas.nativescript.org/tns.xsd"
xmlns:pdf="@nativescript/pdf"
loaded="pageLoaded"
>
<pdf:PDFView src="{{ pdfUrl }}" load="{{ onLoad }}" />
</Page>
import { NativeScriptPdfModule } from '@nativescript/pdf/angular'
@NgModule({
imports: [
NativeScriptCommonModule,
...
NativeScriptPdfModule
],
<PDFView [src]="src" (load)="onLoad()"></PDFView>
There are sample applications avalable: