koajs / session

Simple session middleware for koa
MIT License
902 stars 113 forks source link

How to get user session data manually for socket.io? #166

Open georgyfarniev opened 5 years ago

georgyfarniev commented 5 years ago

Hello, I'm using socket.io and koa-session. How can I get user session information (same as ctx.state.user in koa middleware) in socket context, where I have only cookie session id?

AoDev commented 4 years ago

@georgyfarniev It's an old issue but for anyone seeing it, I use this module: https://github.com/Dongss/koa-socketio-session