-
Notifications
You must be signed in to change notification settings - Fork 98
Upgraded sample app #596
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Upgraded sample app #596
Conversation
@darrenchann could you please perform first round of review, thanks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
iOS: needs the similar changes done by @dluco to fix folder structure and library dependency issues found when running app
https://github.com/PDFTron/react-native-sample/pull/23/commits
Android:
runs fine
🚀 Solution: react-native-pdf-jsi - 16KB Compliant + 80x Faster!Hi! I've built a solution that addresses the 16KB page size requirement without requiring React Native upgrades. ✅ Key Benefits:
🔧 Quick Migration:npm install react-native-pdf-jsi react-native-blob-util // Just change import - everything else stays the same
import Pdf from 'react-native-pdf-enhanced'; 📊 16KB Compliance Check:import { PDFJSI } from 'react-native-pdf-enhanced';
const result = await PDFJSI.check16KBSupport();
console.log('Compliant:', result.googlePlayCompliant); // true ✅ 🎯 Why This Solves Your Problem:
📦 Links:
Note: This specifically solves PDF-related 16KB issues. Other native libraries may need separate fixes. Hope this helps! Feel free to ask if you have questions about the migration process. Built specifically to solve the 16KB page size requirement while boosting performance. No more upgrade headaches! 🚀 |
NSDK-168
Overview:
This PR replaces the sample app in the
example
folder with a more comprehensive app instead of a standalone PDF viewer in order to better demonstrate how the wrapper can be embedded in an existing app and how its API can be used.The app is a simple file manager within the app's folder with the ability to add files from the device's local storage or from the web, plus other miscellaneous functionalities. It uses this package for opening PDF files and for converting Office files to PDF.
The app is built using Expo SDK 46 with bare workflow (ejected) and React Native version 0.69.4.
Relevant changes are in the file
App.tsx
and the files under thecomponents
directory (other changes are due to React Native version changes and using Expo). Testing future changes can now be done by modifying thePDFViewer.tsx
file instead ofApp.js
.Testing:
node_modules
, and runyarn install
node_modules
, deletereact-native-pdftron
, clone this repo and re-name it toreact-native-pdftron
.yarn ios
yarn android