react-native-pdf-lib icon indicating copy to clipboard operation
react-native-pdf-lib copied to clipboard

Saving the pdf created from internal storage to external storage

Open nathan0519 opened this issue 4 years ago • 1 comments

Hi, I am looking to create a pdf using the createPDF and the function works fine but

  1. I do not know how to view the created PDF and
  2. I do not know how to move the created PDF from internal storage to external storage (so that it can be shared/viewed outside the app)

Thanks!

nathan0519 avatar Jun 26 '21 09:06 nathan0519

When it returns the path, you should be able to load the file from there, e.g. something like this:

<PDFPage pdfPath={`${RNFetchBlob.fs.dirs.DocumentDir}/${this.photoBook!.contentPDFPath!}`} />

thekevinbrown avatar Nov 07 '21 23:11 thekevinbrown