rtcstats
rtcstats copied to clipboard
Clarify expected behavior in README
After reading the README, it's not clear to me where the stats will appear...in the browser console, I guessed. To test this, I did:
- Downloaded rtcstats.js
- Uploaded it to the same folder where my verto js lib files are
- Made this the first script execution in my test page:
- Made a test call and monitored the browser console
The call went fine (in Chrome72/incognito/Win10), but I didn't see anything new once the peer must have gotten to ice connection state "completed", nor after hangup.
I would expect that I could pass a callback, probably as a listener to iceconnectionstatechange, and that I could inspect the collected, periodic stats that way. If you would explain a bit what to expect, I'll submit a PR for the README to help clarify. Thanks.
no, they will be sent to an instance of https://github.com/opentok/rtcstats-server via websocket.
https://github.com/opentok/rtcstats#require is the more common way to use this nowadays, the other one should probably be removed from the README