I'm trying to use twilio conversations from javascript in React Native.
I'm getting RangeError: Maximum call stack size exceeded (native stack depth) when calling
const Conversations = require('@twilio/conversations');
Conversations.Client.create(token)
My package.json looks like
{
"@twilio/conversations": "^1.2.2",
"events": "^3.3.0",
"react": "17.0.2",
"react-native": "0.64.2",
"react-native-navigation": "^7.16.0",
"react-native-navigation-hooks": "^6.3.0",
"react-native-twilio-video-webrtc": "https://github.com/blackuy/react-native-twilio-video-webrtc",
"react-stomp": "^5.1.0",
}
Here is the logs
Twilio developer evangelist here.
Can you try importing the module with import
instead of require
? Like:
import {Client} from '@twilio/conversations';
Then you can see more debug information from the client if you change the logLevel
when you create it:
Client.create(token, { logLevel: 'debug' });