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

sysend

Package Overview
Dependencies
Maintainers
1
Versions
41
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sysend - npm Package Compare versions

Comparing version 1.16.2 to 1.16.3

2

package.json
{
"name": "sysend",
"version": "1.16.2",
"version": "1.16.3",
"description": "Communication and Synchronization between browser tabs/windows. Works cross-domain.",

@@ -5,0 +5,0 @@ "main": "sysend.js",

@@ -5,4 +5,4 @@ <p align="center">

[![npm](https://img.shields.io/badge/npm-1.16.2-blue.svg)](https://www.npmjs.com/package/sysend)
![bower](https://img.shields.io/badge/bower-1.16.2-yellow.svg)
[![npm](https://img.shields.io/badge/npm-1.16.3-blue.svg)](https://www.npmjs.com/package/sysend)
![bower](https://img.shields.io/badge/bower-1.16.3-yellow.svg)
![downloads](https://img.shields.io/npm/dt/sysend.svg)

@@ -9,0 +9,0 @@ [![jsdelivr](https://img.shields.io/jsdelivr/npm/hm/sysend)](https://www.jsdelivr.com/package/npm/sysend)

/**@license
* sysend.js - send messages between browser windows/tabs version 1.16.2
* sysend.js - send messages between browser windows/tabs version 1.16.3
*

@@ -8,16 +8,16 @@ * Copyright (C) 2014-2023 Jakub T. Jankiewicz <https://jcubic.pl/me>

*/
type callback = (message: unknown, event: string) => void;
type callback<T> = (message: T, event: string) => void;
interface Sysend {
id: string;
broadcast(event: string, data?: unknown): void;
broadcast<T>(event: string, data?: T): void;
emit(event: string, data?: unknown): void;
on(event: string, callback: callback): void;
off(event: string, callback?: callback): void;
on<T>(event: string, callback: callback<T>): void;
off<T>(event: string, callback?: callback<T>): void;
proxy(...args: string[]): void;
serializer(to: (data: unknown) => string, from: (data: string) => unknown): void;
serializer<T>(to: (data: T) => string, from: (data: string) => T): void;
track(event: 'open', callback: (data: {id: string, count: number, primary: boolean}) => void): void;
track(event: 'close', callback: (data: {id: string, count: number, primary: boolean, self: boolean}) => void): void;
track(event: 'primary', callback: () => void): void;
track(event: 'message', callback: (payload: {data: unknown, origin: string}) => void): void;
track<T>(event: 'message', callback: (payload: {data: T, origin: string}) => void): void;
track(event: 'secondary', callback: () => void): void;

@@ -27,3 +27,3 @@ track(event: 'update', callback: (payload: Array<{ id: string, primary: boolean }>) => void): void;

list(): Promise<Array<{ id: string, primary: boolean }>>;
post(target: string, data?: unknown): void;
post<T>(target: string, data?: T): void;
channel(...domains: string[]): void;

@@ -30,0 +30,0 @@ isPrimary(): boolean;

/**@license
* sysend.js - send messages between browser windows/tabs version 1.16.2
* sysend.js - send messages between browser windows/tabs version 1.16.3
*

@@ -4,0 +4,0 @@ * Copyright (C) 2014-2023 Jakub T. Jankiewicz <https://jcubic.pl/me>

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