rn-pdf-reader-js
rn-pdf-reader-js copied to clipboard
to fix issue on Android device
How to get this fix into production? I'm having same issues with the error on Android
How to get this fix into production? I'm having same issues with the error on Android
try this to resolve:
import PDFReader, { Props } from 'rn-pdf-reader-js'
class MyPDFReader extends PDFReader {
constructor(props: Props | Readonly<Props>) {
super(props);
this.state = { ...this.state, renderedOnce: true };
}
}
....
return (
<MyPDFReader
source={{ uri: uri }}
....
/>
)
Hi, will this be merged into master or is there a solution for JS / React Native?
Update: The above fix by extending the class and adding the "renderedOnce" property worked. Thanks.