
Research
GemStuffer Campaign Abuses RubyGems as Exfiltration Channel Targeting UK Local Government
GemStuffer abuses RubyGems as an exfiltration channel, packaging scraped UK council portal data into junk gems published from new accounts.
react-stomp-client
Advanced tools
A simple STOMP message client for React. It will connect to the provided endpoint on mount, followed immmediately by a subscription to the provided topic. The connection gets cleaned up on unmount.
Easily testable via mock-stomp-broker!
Supports TypeScript.
npm install --save react-stomp-client
import React, { Component } from "react";
import StompClient from "react-stomp-client";
class MyComponent extends Component {
constructor(props) {
this.state = {
latestMessage: null
};
this.handleMessage = this.handleMessage.bind(this);
}
handleMessage(stompMessage) {
this.setState({
latestMessage: stompMessage
});
}
render() {
const { latestMessage } = this.state;
return (
<StompClient
endpoint="ws://localhost:8888/websocket"
topic="my-topic"
onMessage={this.handleMessage}
>
<div>
{latestMessage
? `Latest message received: ${latestMessage}`
: "No message received yet"}
</div>
</StompClient>
);
}
}
| Prop | Required? | Description |
|---|---|---|
endpoint | Yes | The STOMP endpoint to connect to. The server should be up and ready to speak STOMP via WebSocket (the protocol should be either ws or wss). |
topic | No | The STOMP topic to subscribe to. When no topic is provided, no subscription attempt is made. |
onMessage | No | The callback to invoke when a STOMP message arrives. |
children | No | Any React component subtree. Use this to tie the together the lifecycles of the StompClient and any components that depend on data from it. |
reconnectDelay | No | The delay in ms to wait before attempting to reconnect to the endpoint after a connections is interrupted. Defaults to 3000. |
heartbeatIncoming | No | The heartbeat frequency in ms to request from the server. Defaults to 30000. |
heartbeatOutgoing | No | The heartbeat frequency in ms to send to the server. Defaults to 30000. |
FAQs
A React STOMP client
We found that react-stomp-client demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
GemStuffer abuses RubyGems as an exfiltration channel, packaging scraped UK council portal data into junk gems published from new accounts.

Company News
Socket was named to the Rising in Cyber 2026 list, recognizing 30 private cybersecurity startups selected by CISOs and security executives.

Research
Socket detected 84 compromised TanStack npm package artifacts modified with suspected CI credential-stealing malware.