Comments (1)
I'm a little confused on your terminology. WebSockets don't really have a concept of "events or data" like Javascript might have. Now the Ruby server is built using eventmachine which uses the reactor pattern, same as node.js. The ws.onmessage
is the method run when it receives a "message" from a client and runs a block, which in this case writes back to the client with a randomly generated phrase. That being said, if you are looking to send data to the Ruby WebSocket server, you are going to want to use writeString
or writeData
methods. If you wanted to write different structured data (i.e JSON, other strings, etc) that would be up to your implementation.
from starscream.
Related Issues (20)
- Support for visionOS HOT 1
- When can the callback of timeout be supported?
- Endless dependency resolution with Xcode 15.3b3
- Return the response body in HTTPUpgradeError "notAnUpgrade"
- Add suppressed labels to enums
- Getting viabilityChanged error while integration of Starscream Websocket lib
- How to identify which WebSocket closed
- NWProtocolTCP Crash HOT 5
- How to use the WebSocketServer
- [CRASH] swift::fatalError(unsigned int, char const*, ...)
- [CRASH] TCPTransport.write(data:completion:) HOT 1
- Update request header after create websocket
- Client side authentication HOT 1
- Crash WebSocket.createHTTPRequest() WebSocket.swift:591
- Privacy Manifest HOT 10
- Change the didreceive event protocol
- if you socket resart many time,cpu is very busy and Forever and ever
- Crash observed randomly
- Starscream.HTTPUpgradeError.notAnUpgrade(403) HOT 3
- Can I use selfSignedSSL now? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from starscream.