Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

mqtt

Package Overview
Dependencies
Maintainers
7
Versions
203
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mqtt - npm Package Compare versions

Comparing version 5.1.2 to 5.1.3

8

build/lib/TypedEmitter.d.ts

@@ -5,2 +5,4 @@ export type EventHandler = ((arg1: any, arg2: any, arg3: any, arg4: any) => void) | ((arg1: any, arg2: any, arg3: any) => void) | ((arg1: any, arg2: any) => void) | ((arg1: any) => void) | ((...args: any[]) => void);

once<TEvent extends keyof TEvents>(event: TEvent, callback: TEvents[TEvent]): this;
prependListener<TEvent extends keyof TEvents>(event: TEvent, callback: TEvents[TEvent]): this;
prependOnceListener<TEvent extends keyof TEvents>(event: TEvent, callback: TEvents[TEvent]): this;
removeListener<TEvent extends keyof TEvents>(event: TEvent, callback: TEvents[TEvent]): this;

@@ -10,4 +12,10 @@ off<TEvent extends keyof TEvents>(event: TEvent, callback: TEvents[TEvent]): this;

emit<TEvent extends keyof TEvents>(event: TEvent, ...args: Parameters<TEvents[TEvent]>): boolean;
setMaxListeners(n: number): this;
getMaxListeners(): number;
listeners<TEvent extends keyof TEvents>(eventName: TEvent): TEvents[TEvent][];
rawListeners<TEvent extends keyof TEvents>(eventName: TEvent): TEvents[TEvent][];
listenerCount<TEvent extends keyof TEvents>(event: TEvent, listener?: TEvents[TEvent]): number;
eventNames(): Array<keyof TEvents>;
}
export declare class TypedEventEmitter<TEvents extends Record<keyof TEvents, EventHandler>> {
}

2

package.json
{
"name": "mqtt",
"description": "A library for the MQTT protocol",
"version": "5.1.2",
"version": "5.1.3",
"contributors": [

@@ -6,0 +6,0 @@ "Adam Rudd <adamvrr@gmail.com>",

@@ -23,2 +23,11 @@ import EventEmitter from 'events'

): this
prependListener<TEvent extends keyof TEvents>(
event: TEvent,
callback: TEvents[TEvent],
): this
prependOnceListener<TEvent extends keyof TEvents>(
event: TEvent,
callback: TEvents[TEvent],
): this
removeListener<TEvent extends keyof TEvents>(

@@ -32,2 +41,3 @@ event: TEvent,

): this
removeAllListeners(event?: keyof TEvents): this

@@ -39,2 +49,18 @@

): boolean
setMaxListeners(n: number): this
getMaxListeners(): number
listeners<TEvent extends keyof TEvents>(
eventName: TEvent,
): TEvents[TEvent][]
rawListeners<TEvent extends keyof TEvents>(
eventName: TEvent,
): TEvents[TEvent][]
listenerCount<TEvent extends keyof TEvents>(
event: TEvent,
listener?: TEvents[TEvent],
): number
eventNames(): Array<keyof TEvents>
}

@@ -41,0 +67,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc