I've used this npm library which is a react native bridge for adcolony ads SDK , i was supposed to display advertise in my application .
When i imported and used mentioned library in my react native application i got following error:
This is how i use the adcolony SDK in my react-native app:
.
.
.
line 6 : import RNAdColony from 'react-native-ad-colony';
.
.
.
line 187: RNAdColony.setUser("456456456456");
line 188: RNAdColony.showAdReward("vz0533ae6a620249ef91");
How can i solve this problem?
I've recently found the answer of my question :
The above error occurs because linking between SDK and React-native project was not established.
This error occurs because Adcolony.setUser() method was return an undefined and React-native didn't get what happened; eventually an unhandled promise error have been shown .
After a lot of searches, i was understand that when you using Expo to develop your React-native project , Expo needs Expokit which is a library that allows Expo to run React-native commands such as "react-native link" ; in other words, Expokit is an extra library for custom SDK implementation.