# transmitter

> > Dead simple pub-sub

Latest version **3.0.1** (published 2016-07-17) · MIT license · 0 weekly downloads

## Install

```sh
npm install transmitter
pnpm add transmitter
yarn add transmitter
bun add transmitter
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 3.0.1 |
| Published | 2016-07-17 |
| First published | 2015-05-11 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 15 |
| Author | Josh Perez |
| Maintainers | goatslacker |
| Keywords | transmit, pubsub, pub, sub, eventemitter, observable, subscribe |

## Links

- npm: https://www.npmjs.com/package/transmitter
- Repository: https://github.com/goatslacker/transmitter
- Issues: https://github.com/goatslacker/transmitter/issues
- npm.io page: https://npm.io/package/transmitter

## Alternatives

- [async-exit-hook](https://npm.io/package/async-exit-hook.md) — 3.7M weekly downloads
- [evnty](https://npm.io/package/evnty.md) — 7.2K weekly downloads
- [eleventy-plugin-asciidoc](https://npm.io/package/eleventy-plugin-asciidoc.md) — 3.5K weekly downloads
- [@jswork/next-get2get](https://npm.io/package/@jswork/next-get2get.md) — 945 weekly downloads
- [@dashersw/axon](https://npm.io/package/@dashersw/axon.md) — 934 weekly downloads

## Recent versions

- 3.0.1 (latest) — 2016-07-17
- 3.0.0 — 2016-07-17
- 2.0.0 — 2016-03-19
- 1.1.0 — 2015-11-04
- 1.0.2 — 2015-05-19
- 1.0.1 — 2015-05-12
- 1.0.0 — 2015-05-11

## README

# transmitter

> Dead simple pub-sub

## API

### subscribe(onChange: () => any): { dispose: () => void }

Subscribes to change events. Returns an object which contains the method `dispose` which removes the current subscription.

### publish(...payload: any): void

Emit a change to all the subscribers.

## Example

```js
const bus = transmitter()

bus.subscribe(result => console.log(result))

bus.publish({ foo: 'bar' })
```

## License

[MIT](http://josh.mit-license.org)

---
_Source: https://npm.io/package/transmitter · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
