mirror of
https://github.com/github/codeql.git
synced 2025-12-17 17:23:36 +01:00
13 lines
242 B
JavaScript
13 lines
242 B
JavaScript
(function () {
|
|
const WebSocket = require('ws');
|
|
|
|
const ws = new WebSocket('ws://example.org');
|
|
|
|
ws.on('open', function open() {
|
|
ws.send('Hi from client!');
|
|
});
|
|
|
|
ws.on('message', function incoming(data) {
|
|
console.log(data);
|
|
});
|
|
})(); |