web-share-fb
v1.3.6
Published
``` npm install web-share-fb --save
Readme
#Installation
npm install web-share-fb --save
Including in your project:
import Qtalk from 'web-share-fb';###Methods:
Signing anonymous user to RTDB
Qtalk.signInAnnoymously(dbUrl,callId,function(user){
console.log(user);
});
Listening for change in number of participants
Qtalk.participantChangeListener(dbUrl,callId,function(res){
console.log(res);
});This listener callsback with an Object which consits of host information i.e hostState and hostId, and all the participants with their status. eg:
{
"count":2,
"host":{
"id":"DBtprLvCbHOqMU6FxyFSngRO0Hq2",
"hostState":"AVAILABLE"
},
"participants":{
"DBtprLvCbHOqMU6FxyFSngRO0Hq2":"AVAILABLE",
"GiHgtRnYvLUfxa40LY7Mnxastxf1":"AVAILABLE"
}
}
Exit a participant
Qtalk.leaveCall(dbUrl,callId,user);