Open Noitham opened 2 years ago
I have the same problem, any solution?
I have the exact same problem also, glad I'm not alone
+1
I believe its to do with these changes to android policies https://developer.android.com/about/versions/11/privacy/storage
Seems like we may have to find another way to write files on android now
I have found a solution. This library here is quite unmaintained, I've found some guys that are keeping it maintained and updated:
https://github.com/RonRadtke/react-native-blob-util
Had the same issue tho with that library, but found out a solution: https://github.com/RonRadtke/react-native-blob-util/issues/66
Basically adding:
<queries>
<intent>
<action android:name="android.intent.action.VIEW" />
<data android:mimeType="*/*" />
</intent>
</queries>
on the AndroidManifest.xml
Hope that makes it work for you guys, and definitely recommend switching to use the new maintained library!
@Noitham you absolute hero
@Noitham and @RonRadtke are Android 11 MVP's
This module is unmentionable ⚠️! please use fork: https://github.com/RonRadtke/react-native-blob-util
I have found a solution. This library here is quite unmaintained, I've found some guys that are keeping it maintained and updated:
https://github.com/RonRadtke/react-native-blob-util
Had the same issue tho with that library, but found out a solution: RonRadtke#66
Basically adding:
<queries> <intent> <action android:name="android.intent.action.VIEW" /> <data android:mimeType="*/*" /> </intent> </queries>
on the
AndroidManifest.xml
Hope that makes it work for you guys, and definitely recommend switching to use the new maintained library!
it works for me, but still i have problem with .doc and .docs files, it wont open :/
'application/msword'
Hello,
I've been using this library for quite some time in order to open PDF files. Recently, I've updated Android's
targetSdkVersion
to 30, and I've noticed theactionViewIntent
function is not functioning on Android 11. Using it as:android.actionViewIntent(filePath, `application/pdf`);
No error or whatsoever is thrown, so not really possible to debug.
Currently, asking for these permissions on
AndroidManifest.xml
:And have both
preserveLegacyExternalStorage
&requestLegacyExternalStorage
set as true.Using latest
github:joltup/rn-fetch-blob#master
versionHas somebody else faced this issue after updating? Am I missing some specific settings?
Thanks in advance.