Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
@alwatr/observable
Advanced tools
A lightweight and flexible TypeScript library for implementing the observer pattern (similar to signals) with events, subscriptions, and convenient features.
A lightweight and flexible TypeScript library for implementing the observer pattern (similar to signals) with events, subscriptions, and convenient features.
once
, priority
, and receivePrevious
.npm install @alwatr/observable
AlwatrObservable
constructor(config: {name: string; loggerPrefix?: string})
: Creates a new AlwatrObservable
instance.
config.name
: The name of the signal (used for logging).config.loggerPrefix
: Optional prefix for log messages.subscribe(listenerCallback: ListenerCallback<this, T>, options: SubscribeOptions = {}): SubscribeResult
: Subscribes to the signal.
listenerCallback
: The function to be called when an event is emitted.options
:
once
: If true
, the listener will be automatically unsubscribed after the first event.priority
: If true
, the listener will be executed before other listeners.receivePrevious
: If true
, the listener will be immediately called with the last emitted event (if available).disabled
: If true
, the listener will not be executed.unsubscribe(listenerCallback: ListenerCallback<this, T>)
: Unsubscribes a listener from the signal.
notify_(message: T)
: Emits an event to all subscribers.
message
: The data to be sent to the subscribers.clearMessage_()
: Clears the current message without notifying subscribers.
untilNewNotify_()
: Returns a Promise that resolves with the next emitted event.
Contributions are welcome! Please read the contributing guidelines before submitting a pull request.
This project is licensed under the MIT License. See the LICENSE file for details.
3.0.0 (2024-09-17)
token
to crypto
prettier-plugin-tailwindcss
(26fdb04) by @alwatr-icon
: icon component (ddb7180) by @demo
: improve icon demo (9bfa525) by @requestIfNotComplete
(31c8d61) by @user factory
demo (2b82df5) by @i18n
(1775906) by @router2
(a101328) by @server-context
demo (40339a7) by @fsm
(6897c0c) by @bind
vs class
(d5dd6ff) by @signalRecord
to config (255200b) by @i18n2
class base (bf1bec4) by @directive
to show the icons (584cc8e) by @server-context
itself! (f6d78dd) by @event
signal class (71959e0) by @phone
validation (779cfd3) by @src
to .
(76c3fe5) by @token
to crypto
(ad4a74a) by @logger
s & token
(cd73aa5) by @event
demo & sort folders (5f5cb3f) by @fsm
s changes (2d5cd32) by @AlwatrApiRequest
(8776416) by @stat
(ef4d473) by @name
to config
& remove context
(8daeb45) by @config
to an object (ab81fc3) by @initFsmInstance
args (54c0f06) by @src
and move all content to root
(e2f4ce3) by @watch
scripts (fb5b19e) by @class
methods & move outlet
to utility
file (68b75b9) by @_request
& _actionRecord
(a7e3325) by @request
in AlwatrApiRequest
(7a2a9aa) by @super
to this
(13e9604) by @api-request
(71b7fed) by @server-context
to use (15ce6a5) by @base
(a92652e) by @fsm
(1335761) by @AlwatrBaseSignal
(d10f7fa) by @FAQs
A lightweight and flexible TypeScript library for implementing the observer pattern (similar to signals) with events, subscriptions, and convenient features.
The npm package @alwatr/observable receives a total of 103 weekly downloads. As such, @alwatr/observable popularity was classified as not popular.
We found that @alwatr/observable 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
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.