1.0.3 • Published 6 years ago
stable-socket v1.0.3
stable-socket
Install
Install with npm:
npm install stable-socket
API - Set WebSocket, candidate hosts and options
var socket = new StableSocket(require('websockets').WebSocket,
['http://localhost:8000/', 'http://localhost:8001/']
{});
socket.onopen = function() { console.log('Socket opened!') };
socket.send('Hello!');
// => 'Socket opened!'
also use on browser
<script type="text/javascript" src="StableSocket.js"></script>
<script type="text/javascript">
var socket = new StableSocket(WebSocket,
['http://localhost:8000/', 'http://localhost:8001/']
{});
socket.onopen = function() { console.log('Socket opened!') };
socket.send('Hello!');
// => 'Socket opened!'
</script>
1.0.3
6 years ago
1.0.2
6 years ago
1.0.1
6 years ago
1.0.0
6 years ago
0.9.3
6 years ago
0.9.1
7 years ago
0.9.0
7 years ago
0.7.2
7 years ago
0.7.0
7 years ago
0.6.2
7 years ago
0.6.1
7 years ago
0.6.0
8 years ago
0.5.3
8 years ago
0.5.2
8 years ago
0.5.1
8 years ago
0.5.0
8 years ago
0.4.1
8 years ago
0.4.0
8 years ago
0.3.6
8 years ago
0.3.5
8 years ago
0.3.4
8 years ago
0.3.3
8 years ago
0.3.2
8 years ago
0.3.1
8 years ago
0.3.0
8 years ago
0.2.3
9 years ago
0.2.2
9 years ago
0.2.0
9 years ago
0.1.3
9 years ago
0.1.2
9 years ago
0.1.1
9 years ago
0.1.0
9 years ago