A small library for authentication with a user, JWT and socket.io
npm install jwt-socket.io
It is required to have a folder config/ with index.json in the root of the project
{
"dbUri": "databaseURI",
"jwtSecret": "secretkey"
}
the package is assuming you are using mongoose with a user table
I will change all of this later to make it dynamic and flexible
const io = require('socket.io')(server)
const ioAuthCheck = require('io-auth-check')
io.use(ioAuthCheck)
They are not available now