undefined is not an object (evaluating RNFSManager.RNFSFileTypeRegular) on Android
I'm getting undefined is not an object (evaluating RNFSManager.RNFSFileTypeRegular) on Android (on iOS it works fine).
I've seen other issues for this same error yet they are all old and usually suggest manual linking like react-native link react-native-fs.
react-native link react-native-fs doesn't work as react-native doesn't have the link command anymore. Yet I'm facing the same problem with no solution.
How can I get rid of this error on modern (non-manual-linking) React Native for Android?
Please try adding the following permissions to your androidmanifest.xml file and restart the app:
uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"
uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"
@canpoyrazoglu Hey , I have the same issue if you found some way to solve it please let me know
@rezamohdev I don't remember how it got solved (probably was a cached old build intermediate etc. issue). Have you tried @lovishoneworld's solution?
And doing a full clean native (NOT React Native) rebuild is always a good idea.
@canpoyrazoglu , I think I don't use external storage so that's not helpful, I tried to upgrade gradle version because at react-native run-android I get Error at this line : new RNFSPackage(), in MainActivity.java file after upgrading gradle I got a bunch of new error that all looking alien for me, I'm very frustrated,