Skip to content

Tabs Broadcast: JS Library

TabsBroadcast is a lightweight, easy-to-use JavaScript library that enables communication between multiple browser tabs.

TabsBroadcast is a lightweight, easy-to-use JavaScript library that enables communication between multiple browser tabs.

Updated

1 min read

About

TabsBroadcast is a lightweight, easy-to-use JavaScript library that enables communication between multiple browser tabs and is ideal for managing inter-tab communication via the BroadcastChannel API. It implements a singleton pattern to ensure a single instance and allows for registering, emitting, and handling various types of events across different browser tabs. Ideal for web applications that require synchronized data sharing, this package uses the BroadcastChannel API to efficiently exchange messages across open tabs, enhancing the user experience with real-time updates and seamless coordination.

Video

Demo

You can see the demo

Tabs priority

The library also manages primary and slave tabs, ensuring that only one tab is designated as the primary tab, which can perform certain tasks exclusively. With a simple setup and minimal dependencies, tabs-broadcast offers developers a powerful tool for managing state and interactions across tabs in modern web apps.

Features

  • Singleton pattern to ensure a single instance.
  • Inter-tab communication using the BroadcastChannel API.
  • Primary-Slave tab management.
  • Event registration and handling.
  • Emit messages to all tabs or only from the primary tab.
  • Configurable settings.

To see more information on npmjs.com

License

This project is licensed under the MIT License. See the LICENSE file for details.

Keep reading

Related posts

GH Actions tool window in WebStorm: a tree of Glimtide workflow runs with a failed Notarize step and its error log
#dev

GH Actions: I Moved the GitHub Actions Tab Into WebStorm

A WebStorm plugin for GitHub Actions: runs, logs, re-runs and workflow_dispatch in the IDE. Why Glimtide's CI made me write it, and how it is built.

Read
Glims of many colours wave goodbye from a tropical beach as a blue glim sets off on a leaf-sail raft toward the sunrise
#games

Glimtide Is Coming to Steam: What Changed in Nine Days

Glimtide, my living-island life sim, now has a Steam page and heads to Early Access in Q1 2027. Why I removed every coin and what the game got since.

Read
Glimtide logo with a blue glim over the island of Tidemere
#games

Glimtide: A Living Island in the Browser That Never Stops

My new browser game: one shared island of jelly creatures who think, learn and evolve on their own, and an ECS world that takes new mechanics without a restart.

Read

Newsletter

Occasional notes on engineering, game tech, and new tools — no spam, unsubscribe anytime.

Ravy

Engineering manager, founder, and software developer building web platforms, game systems, real-time services, and automation tools. 15 years of shipped work — currently at Gaijin.net.

Get in Touch

Building an MVP, shipping a game feature, or automating a team workflow? Open source or paid — let's talk.

Contact Me
© 2020-2026 XPLOIT FZE. All trademarks, names and logos belong to their respective copyright holders.