Code Monkey home page Code Monkey logo

nativescript-pdf-view's Introduction

NativeScript PDFView

npm npm

๐Ÿšง Work in progress

This package was forked from the unmaintained package madmas/nativescript-pdf-view which in turn is a fork of Merott/nativescript-pdf-view. We are currently cleaning up and updating the code.


A 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.

This plugin does the bare minimum required to render the PDF, no configuration options, and no error handling have been built yet. I welcome all Pull Requests!

My aim is to keep the features consistent across iOS and Android.

Installation

tns plugin add @finanzritter/nativescript-pdf-view

Usage

Vanilla NativeScript

<Page
  xmlns="http://schemas.nativescript.org/tns.xsd"
  xmlns:pdf="@finanzritter/nativescript-pdf-view"
  loaded="pageLoaded">
  <pdf:PDFView src="{{ pdfUrl }}" load="{{ onLoad }}" />
</Page>

Angular NativeScript

import { PDFView } from '@finanzritter/nativescript-pdf-view';
import { registerElement } from 'nativescript-angular';
registerElement('PDFView', () => PDFView);
<PDFView [src]="src" (load)="onLoad()"></PDFView>

Demo

Check out the demo folder for a demo application using this plugin. You can run the demo by executing npm run demo.ios and npm run demo.android from the root directory of the project.

Samples

There are sample applications avalable:

Credits

nativescript-pdf-view's People

Contributors

eddyverbruggen avatar madmas avatar merott avatar sc85 avatar tillsanders avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.