code
const socket = io('http://localhost:3000',{ query: { name: 'Клиент 1' // token: 'blablatoken' }, transportOptions: { polling: { extraHeaders: { 'x-clientToken': '5434543534364009blablatoken' } } } }); will return an error
Request URL: http://localhost:3000/socket.io/?name=%D0%9A%D0%BB%D0%B8%D0%B5%D0%BD%D1%82%201&EIO=3&transport=polling&t=MFfoZYm Request Method: OPTIONS Status Code: 400 Bad Request and in response
{"code":2,"message":"Bad handshake method"} and there is no Cookie header: io = uhcjDl0e_nz60VeJAAAA. and if I remove the additive header (extraHeaders), then everything works fine.
Request URL: http://localhost:3000/socket.io/?name=%D0%9A%D0%BB%D0%B8%D0%B5%D0%BD%D1%82%201&EIO=3&transport=polling&t=MFfq8Dn Request Method: GET Status Code: 200 OK and there is a cookie header: io = uhcjDl0e_nz60VeJAAAA What is the problem? What did I miss?