Nativescript implementation of PSPDFKit.


NativeScript implementation of PSPDFKit (https://pspdfkit.com/). Currently for iOS only, Android support is coming soon.
Please note that this plugin is not production ready. You will have to fork this project to get your licensed version POD installed correctly (currently).
npm install nativescript-pspdfkitModify the activity entry within the AndroidManifest.xml file found in the
``xml
android:label="@string/title_activity_kimera"
android:configChanges="keyboardHidden|orientation|screenSize">
`
Modify the defaultConfig entry within the app.gradle file found in the
``
defaultConfig {
minSdkVersion 19
`ts
import {TNSPSPDFKit} from 'nativescript-pspdfkit';
let licenseKey = '';
let pspdfkit = new TNSPSPDFKit(licenseKey);
/*
TNSPSPDFKitOptions {
scrollDirection?: 'vertical' | 'horizontal';
backgroundColor?: string;
spreadFitting?: 'adaptive' | 'fit' | 'fill';
thumbnailBar?: 'scrollable' | 'scrubber' | 'none';
scrubberBar?: 'verticalRight' | 'verticalLeft';
thumbnailSize?: string;
pageMode?: 'automatic' | 'single' | 'double';
minZoom?: number;
maxZoom?: number;
}
*/
pspdfkit.display('~/example.pdf',{ scrollDirection: 'vertical' });
`
IMPORTANT: Make sure you include xmlns:pspdfkit="nativescript-pspdfkit" on the Page tag
`xml`
`ts`
import { TNSPSPDFView } from 'nativescript-pspdfkit';
import { registerElement } from "nativescript-angular/element-registry";
registerElement("TNSPSPDFView", () => require("nativescript-pspdfkit").TNSPSPDFView);
`html``
Webpack
Setup worker loader -> link
| Property | Default | Type | Required | Description |
| --- | --- | --- | ---| ---|
| scrollDirection | vertical | string |