I am trying to create a peer connection like this:
const iceServers: RTCIceServer[] = data.iceServers.map((s) => {
return {
urls: [s.uri],
username: s.username,
credential: s.credential,
};
});
const configuration: RTCConfiguration = {
iceServers: iceServers,
};
const conn = new RTCPeerConnection(configuration); <-- here comes the error
But I get always an cyclical structure in JSON object
error.
The same error occurs even if I am only using urls: ["stun:stun1.l.google.com:19302",..] without username and credential.
I am using expo, but the project is ejected and running using XCode.
How can I proceed can someone help?