Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
576 views
in Technique[技术] by (71.8m points)

reactjs - Socket.io connection error react native expo

Expo app not connecting to socket server, socket.connected is always false I have tried to downgrade socket.io-client version but it doesn't help. This is the version of socket client: "socket.io-client": "^2.1.1",

const io = require('socket.io-client');

const ROOT_URL = 'ws://mysocketURl/socket.io/';
  var socket = io(ROOT_URL, {
    transports: ['websocket'],
    jsonp: false,
    forceNew: true,
  });

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
等待大神答复

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...