You’re trying to use a web-based library on a mobile Android client. Additionally, your issue revolves around a third-party library that is not part of Expo’s offerings so we don’t provide support for such an issue.
Hi, thanks for the reply at least.
I wrote here, on stackoverflow, on the github repository, on the expo forum, and now on reactflux. I didn’t get help anywhere.
Could you just suggest me which library should I use?
Thank you
The environment in a web browser is different to the environment in a React Native (or Expo) app.
The browser uses something called the DOM (Document Object Model) which is built with HTML and maybe JavaScript. In React Native there is no DOM or HTML, unless you use a WebView (which is basically a web browser window embedded inside your app.)
So this means that if you use a JavaScript library that expects the DOM to exist in your app then it would work on Web, but not on Android or iOS.
To solve this you will have to do one of two things:
Find a replacement to the problematic library that works on all of the platforms you are interested in; or
Check which platform you’re on at run time and run the web-specific code on the web and other code on Android/iOS
So you will first have to identify which library is causing your problem. In the OP’s case it looks to me like a routing/navigation library. So you could try switching to React Navigation which is designed to work on React Native.