Last updated:
0 purchases
pdf js viewer
Features #
only support android and iOS,
Based on the PDF file browser encapsulated in pdf.js, this plugin can help you find out how the PDF you are using cannot display relevant information such as signatures.
Getting started #
import 'package:pdf_js_viewer/pdf_js_viewer.dart';
copied to clipboard
iOS config ATS for info.plist file #
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
copied to clipboard
android config #
AndroidManifest.xml requires configuring HTTP access permissions
<uses-permission android:name="android.permission.INTERNET" />
copied to clipboard
<application
android:usesCleartextTraffic="true"
......
or custom network_security_config.xml in res/xml directory
<application
android:networkSecurityConfig="@xml/network_security_config"
......
copied to clipboard
Usage #
Include short and useful examples for package users. Add longer examples
to /example folder.
import 'package:flutter/material.dart';
import 'package:pdf_js_viewer/pdf_js_viewer.dart';
class PdfViewerPage extends StatefulWidget {
const PdfViewerPage({super.key});
@override
State<PdfViewerPage> createState() => _PdfViewerPageState();
}
class _PdfViewerPageState extends State<PdfViewerPage> {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(title: const Text('PDF Detail'),),
// body: PDFViewerWidget.data(data),
// body: PDFViewerWidget.file(path),
// body: PDFViewerWidget.network(path),
// body: PDFViewerWidget.assets(path),
);
}
}
copied to clipboard
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.