cube-js / cube

📊 Cube — The Semantic Layer for Building Data Applications
https://cube.dev
Other
17.89k stars 1.77k forks source link

Cubejs-client/core and react is not working in react-native #6759

Open akg16800 opened 1 year ago

akg16800 commented 1 year ago

Actually, I'm using React native version 0.71 for building an analytics app, so I Im using cubejs for that. So, the problem is that when I import the package of @cubejs-client/core and @cubejs-client/react the screen becomes blank and hangs and the Maximum call stack size exceeded and some internal recursion is going on

I have also done the full stack trace report of the app and it shows errors like

             │ TypeError: An error was thrown when attempting to render log messages via LogBox.
                         │ 
                         │ undefined is not a function, js engine: hermes
                         │ RangeError: Maximum call stack size exceeded (native stack depth), js engine: hermes
                         │ TypeError: An error was thrown when attempting to render log messages via LogBox.
                         │ 
                         └ undefined is not a function, js engine: hermes

Currently i have used version of 0.33.12 of these packages(@cubejs-client/core and @cubejs-client/react )

I have downgraded my react-native version and also used a lower version of cubejs packages but still I got the same error

And by disabling the hermes it giving errors like this

TypeError: An error was thrown when attempting to render log messages via LogBox.

_$$_REQUIRE(dependencyMap[2], "../internals/is-constructor") is not a function. (In '$$_REQUIRE(dependencyMap[2], "../internals/is-constructor")(C)', '$$_REQUIRE(_dependencyMap[2], "../internals/is-constructor")' is an instance of Object)

Screenshot_2023-06-21-18-44-23-207_com analyticsapp this is a screenshot of the app page when I import the package in the App.js file

Describe the solution you'd like So Actually I want to give some ways to integrate or make the package of @cubejs-client/core and @cubejs-client/react so that it will be compatible to React-native

github-actions[bot] commented 1 year ago

If you are interested in working on this issue, please leave a comment below and we will be happy to assign the issue to you. If this is the first time you are contributing a Pull Request to Cube.js, please check our contribution guidelines. You can also post any questions while contributing in the #contributors channel in the Cube.js Slack.

igorlukanin commented 1 week ago

I believe it is more correct to classify this as a feature request rather than a bug. React client library was never intended/tested to work with React Native. It's primary purpose is to power web-based applications.