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

@types/ws

Package Overview
Dependencies
Maintainers
1
Versions
77
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/ws - npm Package Compare versions

Comparing version 4.0.1 to 4.0.2

27

ws/index.d.ts

@@ -7,2 +7,3 @@ // Type definitions for ws 4.0

// Philippe D'Alva <https://github.com/TitaneBoy>
// Orblazer <https://github.com/orblazer>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped

@@ -71,10 +72,10 @@

// Events
on(event: 'close', listener: (code: number, reason: string) => void): this;
on(event: 'error', listener: (err: Error) => void): this;
on(event: 'upgrade', listener: (request: http.IncomingMessage) => void): this;
on(event: 'message', listener: (data: WebSocket.Data) => void): this;
on(event: 'open' , listener: () => void): this;
on(event: 'ping' | 'pong', listener: (data: Buffer) => void): this;
on(event: 'unexpected-response', listener: (request: http.ClientRequest, response: http.IncomingMessage) => void): this;
on(event: string | symbol, listener: (...args: any[]) => void): this;
on(event: 'close', listener: (this: WebSocket, code: number, reason: string) => void): this;
on(event: 'error', listener: (this: WebSocket, err: Error) => void): this;
on(event: 'upgrade', listener: (this: WebSocket, request: http.IncomingMessage) => void): this;
on(event: 'message', listener: (this: WebSocket, data: WebSocket.Data) => void): this;
on(event: 'open' , listener: (this: WebSocket) => void): this;
on(event: 'ping' | 'pong', listener: (this: WebSocket, data: Buffer) => void): this;
on(event: 'unexpected-response', listener: (this: WebSocket, request: http.ClientRequest, response: http.IncomingMessage) => void): this;
on(event: string | symbol, listener: (this: WebSocket, ...args: any[]) => void): this;

@@ -186,7 +187,7 @@ addListener(event: 'close', listener: (code: number, message: string) => void): this;

// Events
on(event: 'connection', cb: (socket: WebSocket, request: http.IncomingMessage) => void): this;
on(event: 'error', cb: (error: Error) => void): this;
on(event: 'headers', cb: (headers: string[], request: http.IncomingMessage) => void): this;
on(event: 'listening', cb: () => void): this;
on(event: string | symbol, listener: (...args: any[]) => void): this;
on(event: 'connection', cb: (this: WebSocket, socket: WebSocket, request: http.IncomingMessage) => void): this;
on(event: 'error', cb: (this: WebSocket, error: Error) => void): this;
on(event: 'headers', cb: (this: WebSocket, headers: string[], request: http.IncomingMessage) => void): this;
on(event: 'listening', cb: (this: WebSocket) => void): this;
on(event: string | symbol, listener: (this: WebSocket, ...args: any[]) => void): this;

@@ -193,0 +194,0 @@ addListener(event: 'connection', cb: (client: WebSocket) => void): this;

{
"name": "@types/ws",
"version": "4.0.1",
"version": "4.0.2",
"description": "TypeScript definitions for ws",

@@ -26,2 +26,7 @@ "license": "MIT",

"githubUsername": "TitaneBoy"
},
{
"name": "Orblazer",
"url": "https://github.com/orblazer",
"githubUsername": "orblazer"
}

@@ -39,4 +44,4 @@ ],

},
"typesPublisherContentHash": "6570a37fea4c6f9f4d0592253926e8be0b4e436e647f8eb7cb9f3fd14bed9bb0",
"typesPublisherContentHash": "b35a345f45e2615d5973b9fe5717b79e0c973a6500c66455b16dce72838bea90",
"typeScriptVersion": "2.0"
}

@@ -11,3 +11,3 @@ # Installation

Additional Details
* Last updated: Tue, 13 Feb 2018 02:54:18 GMT
* Last updated: Wed, 28 Mar 2018 17:46:05 GMT
* Dependencies: events, http, https, net, node

@@ -17,2 +17,2 @@ * Global values: none

# Credits
These definitions were written by Paul Loyd <https://github.com/loyd>, Matt Silverlock <https://github.com/elithrar>, Margus Lamp <https://github.com/mlamp>, Philippe D'Alva <https://github.com/TitaneBoy>.
These definitions were written by Paul Loyd <https://github.com/loyd>, Matt Silverlock <https://github.com/elithrar>, Margus Lamp <https://github.com/mlamp>, Philippe D'Alva <https://github.com/TitaneBoy>, Orblazer <https://github.com/orblazer>.

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