Best way to manage Chat channels in Firebase

后端 未结 4 1959
时光取名叫无心
时光取名叫无心 2020-11-22 01:25

In my main page I have a list of users and i\'d like to choose and open a channel to chat with one of them.

I am thinking if use the id is the best way and control a

4条回答
  •  半阙折子戏
    2020-11-22 01:51

    Hashing with js-sha256 module worked for me with directions of Frank van Puffelen and Eduard.

    import SHA256 from 'crypto-js/sha256'
    let agentId = 312
    let userId = 567
    let chatHash = SHA256('agent:' + agentId + '_user:' + userId)
    

提交回复
热议问题