npm.io
2.0.0 • Published 1 month ago

@metamask/messenger

Licence
MIT
Version
2.0.0
Deps
1
Size
268 kB
Vulns
0
Weekly
0
Stars
410

@metamask/messenger

A type-safe message bus library.

The Messenger class allows registering functions as 'actions' that can be called elsewhere, and it allows publishing and subscribing to events. Both actions and events are identified by namespaced strings.

Installation

yarn add @metamask/messenger

or

npm install @metamask/messenger

Contributing

This package is part of a monorepo. Instructions for contributing can be found in the monorepo README.

Keywords