Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
@stomp/rx-stomp
Advanced tools
Readme
This library provides an RxJS oriented STOMP over WebSocket client for Web browser and node.js applications.
Please visit https://stomp-js.github.io/ for guides, FAQs and API docs.
This library allows you to connect to a STOMP broker over WebSocket. This library supports complete STOMP specifications including all current protocol variants. Most popular messaging brokers support STOMP and STOMP over WebSockets out-of-the-box or using plugins.
This library uses https://github.com/stomp-js/stompjs under the hood.
The npm package includes TypeScript definitions, so there is no need to install it separately.
<script type="importmap">
{
"imports": {
"@stomp/rx-stomp": "https://ga.jspm.io/npm:@stomp/rx-stomp@2.0.0/esm6/index.js"
},
"scopes": {
"https://ga.jspm.io/": {
"@stomp/stompjs": "https://ga.jspm.io/npm:@stomp/stompjs@7.0.0/esm6/index.js",
"rxjs": "https://ga.jspm.io/npm:rxjs@7.8.0/dist/esm5/index.js",
"tslib": "https://ga.jspm.io/npm:tslib@2.5.0/modules/index.js",
"uuid": "https://ga.jspm.io/npm:uuid@9.0.0/dist/esm-browser/index.js"
}
}
}
</script>
<!-- ES Module Shims: Import maps polyfill for modules browsers without import maps support (all except Chrome 89+) -->
<script async src="https://ga.jspm.io/npm:es-module-shims@1.5.1/dist/es-module-shims.js" crossorigin="anonymous"></script>
<script type="module">
import { RxStomp } from "@stomp/rx-stomp";
const rxStomp = new RxStomp();
rxStomp.configure({
brokerURL: 'ws://localhost:15674/ws',
});
rxStomp.activate();
const subscription = rxStomp
.watch({ destination: "/topic/test-rx" })
.subscribe((message) => console.log(message.body));
rxStomp.publish({
destination: "/topic/test-rx",
body: "First message to RxStomp",
});
setTimeout(async () => {
subscription.unsubscribe();
await rxStomp.deactivate();
}, 3000);
</script>
$ npm install @stomp/rx-stomp ws
import { RxStomp } from "@stomp/rx-stomp";
import { WebSocket } from 'ws';
Object.assign(global, { WebSocket});
const rxStomp = new RxStomp();
rxStomp.configure({
brokerURL: 'ws://localhost:15674/ws',
});
rxStomp.activate();
const subscription = rxStomp
.watch({ destination: "/topic/test-rx" })
.subscribe((message) => console.log(message.body));
rxStomp.publish({
destination: "/topic/test-rx",
body: "First message to RxStomp",
});
setTimeout(async () => {
subscription.unsubscribe();
await rxStomp.deactivate();
}, 3000);
See https://stomp-js.github.io/ for instructions and tutorials.
See samples at: https://github.com/stomp-js/samples/.
API documentation at: https://stomp-js.github.io/api-docs/latest/classes/RxStomp.html.
Please visit Change Log.
If you want to understand the code, develop, or contribute. Please visit How to contribute.
License - Apache-2.0
FAQs
RxJS STOMP client for Javascript and Typescript
The npm package @stomp/rx-stomp receives a total of 40,144 weekly downloads. As such, @stomp/rx-stomp popularity was classified as popular.
We found that @stomp/rx-stomp demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.