-
Notifications
You must be signed in to change notification settings - Fork 642
Open
Description
I am testing on Android. When a PDF file is opened, the progress value is stuck at 0, and it loads the PDF after a few seconds. I am using an HTTPS URL.
Sample URL: https://<file-url>/content?access_token=<access-token>
If I use the rn-fetch-blob package instead of react-native-blob-util, the progress is shown. Tested by changing the import in react-native-pdf/index.js:
import ReactNativeBlobUtil from 'rn-fetch-blob'
I doubt the issue is related to this - RonRadtke/react-native-blob-util#235,
But if I set useDownloadManager to true as given below in react-native-pdf/index.js, the progress is shown, but it gets stuck at the end and does not load the PDF.
this.lastRNBFTask = ReactNativeBlobUtil.config({
// response data will be saved to this path if it has access right.
path: tempCacheFile,
trusty: this.props.trustAllCerts,
addAndroidDownloads: {
useDownloadManager: true
}
})
Note
- My URL does not return a
Content-Lengthheader. - If I hardcode the below URL, it shows the progress:
https://morth.nic.in/sites/default/files/dd12-13_0.pdf
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels