javascript - Store socketId session for sending private messages using Sails -


im building chat app , im trying implement private messaging functionality. each user registers , logs in app credentials guess should storing maybe socketid in user session in order access each client same id no matter page refresh occurs. have seen examples in previous version of sails https://github.com/balderdashy/sailschat , seem use onconnect function in config/sockets.js. can send messages specific user using user.message(id, data) have been changed in sails 0.11 , beforeconnect kinda confusing. if can point me out in right direction appreciated.


Popular posts from this blog

c# - ODP.NET Oracle.ManagedDataAccess causes ORA-12537 network session end of file -

matlab - Compression and Decompression of ECG Signal using HUFFMAN ALGORITHM -

utf 8 - split utf-8 string into bytes in python -