npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@ably/pubsub-core

v3.3.0

Published

Ably-internal core of the Ably Pub/Sub JavaScript SDK: the Pub/Sub API types and the runtime classes shared with the SDKs layered on it. Install @ably/pubsub-device or @ably/pubsub-server instead

Readme

@ably/pubsub-core

This package is Ably-internal. It is published so that the packages below can depend on it, and is not intended to be installed directly.

Install one of these instead, according to where your code runs:

| Your code runs on | Install | | ------------------------------------------------------------------------------- | -------------------------------------------------------------------------- | | An end user's device — browser, React Native, Electron, mobile or desktop app | @ably/pubsub-device | | Infrastructure you operate — a Node.js server, container or serverless function | @ably/pubsub-server |

Both re-export this package's public API, and both create clients through factories that declare which side of the connection you are on. Those factories are the only way to create a client: this package's public API declares the clients' interfaces, PubSubRealtimeClient and PubSubHttpClient, but no class to construct them from. That declaration is what lets Ably tell your users' traffic apart from your own backend's, which in turn determines how connections count toward your account's monthly active users.

What this package is

The API of the Ably Pub/Sub JavaScript SDK, which @ably/pubsub-device and @ably/pubsub-server implement, and which the SDKs layered on Pub/Sub, such as Chat and Spaces, are written against. It carries no client implementation: each per-side package bundles its own.

It also carries the few runtime classes that those packages share: ErrorInfo, PartialErrorInfo and EventEmitter. There is exactly one copy of each, here, so that an error raised by any of those packages passes instanceof ErrorInfo against the class imported from any other. That is why it is a dependency of each per-side package rather than bundled into them.

Its public API surface is defined in ably.d.ts, which re-exports types.d.ts and http.d.ts, and the API reference is generated from it.

Contributing

See the repository README and CONTRIBUTING.md.