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

intertalk

v0.0.21

Published

asynchronous events for NodeJS and the web

Readme

InterTalk

Table of Contents generated with DocToc

InterTalk

API

  • emit_on_event: ( element, event_name, note_name ) -> (only in browser): given a DOM element, a DOM event_name and a note name, when a matching event is triggered on the element, emit a note with $key: note_name and $value: event

    • when emit_on_event is called with the arguments ( event_name, note_name ) then the event listener will be attached to document: IT.emit_on_event div_1, 'click', 'bar' will be triggered when clicking on the div_1 element only, but IT.emit_on_event 'click', 'bar' will be triggered by any click anywhere within the browser document window.
  • unsubscribe: ( listener ) ->: unsubscribe listener from all notifications.

  • unsubscribe: ( $key, listener ) ->: unsubscribe listener from notifications matching $key.

Is Done

  • [+] allow to use Map (or other suitable replacement) instead of WeakMap where Symbols are not allowed as keys (true for Firefox at least up to v124.0.1)
  • [+] fix some names:
    • class Async_events (-> Intertalk?)
    • class AE_Event (-> Note)
    • instance ae_event (-> note?)
    • class AE_Event_results (-> Results)
    • datom key ae_event-results ($results)
  • [+] export singular instance of Intertalk, provide other names as properties (?)
  • [+] remove ability to discover suitably named note listeners on objects as it only leads to complications
  • [+] reconstruct listener registration:
    • in a Map (needed for symbol $keys), store WeakSets as values,
    • likewise, make Intertalk#any_listeners a WeakMap
    • may later want to cache association between $keys and listeners to avoid to re-construct sets
  • [+] implement on_any() or similar to catch all emitted notes
  • [+] implement off() to unsubscribe a listener
  • [+] implement signature off $key, listener to unsubscribe a listener only from matching notes
  • [+] implement on_unhandled() or similar to catch all notes that were emitted but not listened to

To Do

  • [–] event namespacing

  • [–] in emit_on_event(), allow to transform / add attributes to outgoing note

  • [–] implement once() for listeners that should only receive a single note (this requires implementing off()) implement returning a 'command' instance that may contain the listener's results, if any, but also controls how to deal with the current note and whether or not to unsubscribe the listener. Alternatively, either (1) pass in a second argument (dubbed control or ctrl) that contains methods to unsubscribe, cancel &c, or (2) describe how to achieve this by using the intertalk instance's methods

    • off: () ->: unsubscribe this listener from this $key
    • off_all: () ->: unsubscribe this listener from all keys, including any and fallback subscriptions
  • [–] implement note cancellation / note rewrite