Skip to content
This repository has been archived by the owner on Mar 16, 2019. It is now read-only.

Undefined is not an object(evaluating 'RNFetchBlob.DocumentDir') #691

Open
safeimuslim opened this issue Apr 19, 2018 · 12 comments
Open

Undefined is not an object(evaluating 'RNFetchBlob.DocumentDir') #691

safeimuslim opened this issue Apr 19, 2018 · 12 comments

Comments

@safeimuslim
Copy link

safeimuslim commented Apr 19, 2018

Hi, can you help me about this error.

"react": "16.0.0",
"react-native": "0.50.4",

screen shot 2018-04-19 at 16 09 01

@quarkcore
Copy link

quarkcore commented Apr 19, 2018

same issue here.

"react": "16.3.0-alpha.1",
"react-native": "0.54.3",

UPDATE:
solved by correctly adding the package on native side, because react-native link have not done it correctly.

@safeimuslim
Copy link
Author

safeimuslim commented Apr 20, 2018

@quarkcore
Copy link

@safeimuslim
i use the application implementation of react-native-navigation where it has another method to register native modules.
espacially i have no idea about ios on native because im comming from the android world..

i only found out that the error is normaly caused if not registered on native properly.

@JulianKingman
Copy link

This is kind of crazy, I've rarely see so many duplicate issues...

Duplicate issues with potential solutions
#627
#251 (for me this comment helped, if using cocoapods, "be sure to run pod install after linking": #251 (comment))
#454
#386
#371
#350
#84
#51
#30

Duplicates without much info:
#594
#383

@lisa-ewart
Copy link

npm install && react-native link
worked for me!

@nihp
Copy link

nihp commented Aug 1, 2018

npm install && react-native link not worked for me. Any other solution

@beenadevi1
Copy link

Hello i have solved this issue for iOS---- when you install the react-native-fetch-blob and link with iOS, it only provide limited lib on native side.

you can to open project from iOS in Xcode then remove the library of RNFetchBlob.xcodeproj from library folder and then again add by right click on library folder from node modules-->react-native-fetch-blob--->iOS folder --->add project RNFetchBlob.xcodeproj then all required file will be there and make sure add lib on build phases also libRNFetchBlob.a

it works for me.

Thanks

@tiyunchen
Copy link

not work for me in windows

@dilipchandima
Copy link

npm link or manual configuration both not working for me

@tinni95
Copy link

tinni95 commented Jan 8, 2019

me too cannot make this work
{
"name": "my-new-project",
"main": "node_modules/expo/AppEntry.js",
"private": true,
"scripts": {
"start": "expo start",
"android": "expo start --android",
"ios": "expo start --ios",
"eject": "expo eject",
"test": "node ./node_modules/jest/bin/jest.js --watchAll"
},
"jest": {
"preset": "jest-expo"
},
"dependencies": {
"@expo/samples": "2.1.1",
"expo": "^30.0.1",
"moment": "^2.23.0",
"react": "16.3.1",
"react-native": "https://github.com/expo/react-native/archive/sdk-30.0.0.tar.gz",
"react-native-elements": "^0.19.1",
"react-native-email": "^1.0.2",
"react-native-fetch-blob": "^0.10.8",
"react-native-image-picker": "^0.28.0",
"react-native-modal-datetime-picker": "^6.0.0",
"react-native-responsive-screen": "^1.2.0",
"react-native-router-flux": "^4.0.6",
"react-native-select-input-ios": "^2.0.1",
"react-navigation": "^2.18.3",
"rn-fetch-blob": "^0.10.15"
},
"devDependencies": {
"jest-expo": "32.0.0"
}
}
The error I get:
screenshot 2019-01-08 at 02 18 42

@rgamaesilva
Copy link

same issue here.

"react": "16.3.0-alpha.1",
"react-native": "0.54.3",

UPDATE:
solved by correctly adding the package on native side, because react-native link have not done it correctly.

HOw did you do it exactly? Do you recall? What do you mean adding package on native side??

@abdurahmanadilovic
Copy link

Solved it for my self by doing

npm install react-native-fetch-blob
react-native link

then manually adding libRNFetchBlob.a to "Link Binary with Libraries"

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests