
Research
/Security News
Toptal’s GitHub Organization Hijacked: 10 Malicious Packages Published
Threat actors hijacked Toptal’s GitHub org, publishing npm packages with malicious payloads that steal tokens and attempt to wipe victim systems.
@cxl/rx is a lightweight reactive programming library focused on usability, performance, and type safety.
@cxl/rx is a lightweight reactive programming library focused on usability, performance, and type safety.
npm install @cxl/rx
Subject
, OrderedSubject
, BehaviorSubject
, ReplaySubject
, and Reference
for various use cases.pipe
, from
, of
, concat
, merge
, and more for observable creation and composition.Install the package via npm:
npm install @cxl/rx
Or with yarn:
yarn add @cxl/rx
import { observable } from '@cxl/rx';
const myObservable = observable(observer => {
observer.next('Hello');
observer.next('World');
observer.complete();
});
myObservable.subscribe({
next: value => console.log(value),
complete: () => console.log('Done'),
});
import { of } from '@cxl/rx';
of(1, 2, 3, 4)
.map(x => x * 2),
.filter(x => x > 4),
.subscribe(console.log); // Outputs: 6, 8
import { subject } from '@cxl/rx';
const mySubject = subject<number>();
mySubject.subscribe({
next: value => console.log(`Observer 1: ${value}`),
});
mySubject.next(1);
mySubject.next(2);
mySubject.subscribe({
next: value => console.log(`Observer 2: ${value}`),
});
mySubject.next(3);
External cancellation mechanisms for better control:
import { cancel, timer } from '@cxl/rx';
const signal = cancel();
timer(5000).subscribe({
next: () => console.log('Completed after 5s'),
signal, // Link the cancellation signal
});
// Cancel the timer before it completes
signal.next();
Convert promises into observables:
import { fromPromise } from '@cxl/rx';
const observable = fromPromise(Promise.resolve('Hello World'));
observable.subscribe(console.log); // Outputs: Hello World
FAQs
@cxl/rx is a lightweight reactive programming library focused on usability, performance, and type safety.
The npm package @cxl/rx receives a total of 1 weekly downloads. As such, @cxl/rx popularity was classified as not popular.
We found that @cxl/rx demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 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.
Research
/Security News
Threat actors hijacked Toptal’s GitHub org, publishing npm packages with malicious payloads that steal tokens and attempt to wipe victim systems.
Research
/Security News
Socket researchers investigate 4 malicious npm and PyPI packages with 56,000+ downloads that install surveillance malware.
Security News
The ongoing npm phishing campaign escalates as attackers hijack the popular 'is' package, embedding malware in multiple versions.