Closed jcorkhill closed 4 years ago
i checked the code blame and it was like committed 2 yrs ago. From my personal perspective there's nothing wrong to setstate within addStream function. Maybe it's for some old version sdk. You may checkout https://github.com/AgoraIO/Basic-Video-Broadcasting/tree/master/OpenLive-Web to see if this demo works for you as well.
and https://webdemo.agora.io/agora-web-showcase/examples/OpenLive-Web/#/ for quick demo try out.
Thanks @plutoless. I'll take a look. I ended up building my own version with Refs and Hooks.
Hello.
On line 48, right here, you state that it's not recommended to call
setState
in theaddStream
function, but yet you go ahead and do that anyway on line 250, right here.I'm wondering why that's not recommended and how it should be rectified.
Thanks.