# setfrequency

> just like setInterval but based on frequency not period

Latest version **1.0.0** (published 2020-09-05) · MIT license · 0 weekly downloads

## Install

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

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2020-09-05 |
| First published | 2013-11-12 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 5.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Peter Brandt |
| Maintainers | pbrandt1 |
| Keywords | setInterval, frequency |

## Links

- npm: https://www.npmjs.com/package/setfrequency
- Repository: https://github.com/pbrandt1/setFrequency
- Homepage: https://github.com/pbrandt1/setFrequency#readme
- Issues: https://github.com/pbrandt1/setFrequency/issues
- npm.io page: https://npm.io/package/setfrequency

## Recent versions

- 1.0.0 (latest) — 2020-09-05
- 0.0.3 — 2013-11-19
- 0.0.2 — 2013-11-19
- 0.0.1 — 2013-11-12

## README

# setFrequency

just like setInterval but based on frequency instead of period. Maximum 1000 Hz.

```sh
npm install setfrequency
```

```js
import setFrequency from 'setfrequency';

const frameRate = 24
const renderLoop = setFrequency(render, frameRate);

// you can stop if you want
document.querySelector('.pause').addEventListener('click', () => renderLoop.stop())
```

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