1
By default the socket.io generates a unique id. I need this id to be the same id as the user in the database. Have any way to set the id?
if not, how my client front recovers the id generated by the socket?
Front codes
this.socket = Ws(wsUrl, {});
this.connection = this.socket.connect(); //qual o id conectado?
this.chat = this.socket.subscribe('chat');
Code api adonisjs
constructor({ socket, request }) {
this.socket = socket;
this.request = request;
console.log(socket.id) //id do client
}