# scroll-bus

> Tiny library to centralize scroll handlers.

Latest version **2.1.0** (published 2019-06-27) · MIT license · 0 weekly downloads

## Install

```sh
npm install scroll-bus
pnpm add scroll-bus
yarn add scroll-bus
bun add scroll-bus
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.1.0 |
| Published | 2019-06-27 |
| First published | 2017-03-09 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 2 |
| Unpacked size | 7.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | First+Third |
| Maintainers | alaguna, aleperez92, jga, orthagonal1 |
| Keywords | browser, scroll, handler |

## Links

- npm: https://www.npmjs.com/package/scroll-bus
- Repository: https://github.com/firstandthird/scroll-bus
- Homepage: https://github.com/firstandthird/scroll-bus#readme
- Issues: https://github.com/firstandthird/scroll-bus/issues
- npm.io page: https://npm.io/package/scroll-bus

## Dependencies (2)

- [domassist](https://npm.io/package/domassist.md) ^2.2.0
- [tinybounce](https://npm.io/package/tinybounce.md) ^1.2.0

## Alternatives

- [@opentelemetry/exporter-zipkin](https://npm.io/package/@opentelemetry/exporter-zipkin.md) — 14.8M weekly downloads
- [pusher-js](https://npm.io/package/pusher-js.md) — 2.0M weekly downloads
- [browserify](https://npm.io/package/browserify.md) — 1.7M weekly downloads
- [sqs-consumer](https://npm.io/package/sqs-consumer.md) — 1.7M weekly downloads
- [@sanity/eventsource](https://npm.io/package/@sanity/eventsource.md) — 930.8K weekly downloads

## Recent versions

- 2.1.0 (latest) — 2019-06-27
- 2.0.0 — 2019-04-05
- 1.0.3 — 2018-08-29
- 1.0.2 — 2017-04-19
- 1.0.1 — 2017-04-18
- 1.0.0 — 2017-03-09

## README

# Scroll Bus

[![Build Status](https://travis-ci.org/firstandthird/scroll-bus.svg?branch=master)](https://travis-ci.org/firstandthird/scroll-bus)
<span class="scroll-bus-npmversion"><a href="https://npmjs.org/package/scroll-bus" title="View this project on NPM"><img src="https://img.shields.io/npm/v/scroll-bus.svg" alt="NPM version" /></a></span>

Tiny library to centralize scroll handlers.

```javascript
import ScrollBus from 'scroll-bus';

ScrollBus.on(event => {
  // Do stuff
});

// Debounced
ScrollBus.on(event => {
  // Do stuff
}, 150);

// Debounced and immediate
ScrollBus.on(event => {
  // Do stuff
}, 150, true);

// Removes handler
ScrollBus.off(handler);

// Removes all handlers
ScrollBus.off();
```

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