javascript websockets - control initial connection/when does onOpen get bound

后端 未结 5 1198
没有蜡笔的小新
没有蜡笔的小新 2020-12-25 11:08

Two related questions that may be more rooted in my lack of knowledge of how/if browsers pre-parse javascript:

var ws = new WebSocket(\"ws://ws.my.url.com\")         


        
5条回答
  •  情话喂你
    2020-12-25 11:59

    No actual I/O will happen until after your script finishes executing, so there should not be a race condition.

提交回复
热议问题