Socket
Socket
Sign inDemoInstall

airfone-client-js

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

airfone-client-js - npm Package Compare versions

Comparing version 0.0.5 to 0.0.6

4

lib/index.d.ts

@@ -14,3 +14,3 @@ export declare type StatusEvent = 'connect' | 'disconnect' | 'online' | 'offline' | 'error';

export declare type ConnectState = 0 | 1 | 2 | 3;
declare class Payload {
declare interface Payload {
readonly from: any;

@@ -32,5 +32,5 @@ readonly time: number;

broadcast(payload: any): void;
on(event: StatusEvent | MessageEvent | String, handle: (payload: Payload) => {}): AirfoneClient;
on(event: StatusEvent | MessageEvent | String, handle?: (payload: Payload) => void): AirfoneClient;
}
export declare function getClient(options: ClientOptions): AirfoneClient;
export {};

@@ -106,3 +106,3 @@ import { io } from 'socket.io-client';

}
on(event, handle) {
on(event, handle = (payload) => { }) {
if (this.state != 0) {

@@ -109,0 +109,0 @@ throw new Error('监听必须在调用connect方法之前添加');

{
"name": "airfone-client-js",
"version": "0.0.5",
"version": "0.0.6",
"description": "",

@@ -5,0 +5,0 @@ "main": "./lib/index",

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