# time-events-manager

> View and Manage Javascript's timeout and interval collections

Latest version **0.1.1** (published 2018-02-23) · MIT license · 0 weekly downloads

## Install

```sh
npm install time-events-manager
pnpm add time-events-manager
yarn add time-events-manager
bun add time-events-manager
```

## Health

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

Positive: has types; no vulnerabilities.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2018-02-23 |
| First published | 2017-04-22 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 68.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 16 |
| Author | Ziv Polack and Bar Goldinfeld |
| Maintainers | bargoldi, polackziv |
| Keywords | javascript, time, events, timing, events, timeout, interval, timer-events-manager, view-timeouts, javascript-view-timeouts, manage-timeouts, view-intervals, javascript-view-intervals, manage-intervals, timeout-collection, interval-collection |

## Links

- npm: https://www.npmjs.com/package/time-events-manager
- Repository: https://github.com/bargoldi/time-events-manager
- Homepage: https://github.com/bargoldi/time-events-manager#readme
- Issues: https://github.com/bargoldi/time-events-manager/issues
- npm.io page: https://npm.io/package/time-events-manager

## Alternatives

- [@js-joda/timezone](https://npm.io/package/@js-joda/timezone.md) — 383.4K weekly downloads
- [chartjs-adapter-moment](https://npm.io/package/chartjs-adapter-moment.md) — 210.8K weekly downloads
- [strftime](https://npm.io/package/strftime.md) — 171.2K weekly downloads
- [vue-flatpickr-component](https://npm.io/package/vue-flatpickr-component.md) — 115.8K weekly downloads
- [timepicker](https://npm.io/package/timepicker.md) — 51.0K weekly downloads

## Recent versions

- 0.1.1 (latest) — 2018-02-23
- 0.1.0 — 2018-02-21
- 0.0.6 — 2017-05-11
- 0.0.5 — 2017-05-11
- 0.0.4 — 2017-05-11
- 0.0.3 — 2017-04-24
- 0.0.2 — 2017-04-22

## README

# time-events-manager
View and Manage Javascript's timeout and interval collections

# Installation

```$ npm install time-events-manager --save```


```html
<script src="../dist/main.min.js"></script>
```

# Usage

```javascript
// creating a timeout

function myFunc(){
    console.log("Hello world");
}

var myTimeoutId = setTimeout(myFunc, 5000); 

// Managing timeouts via timeoutCollection object

timeoutCollection.get(0);
timeoutCollection.getById(myTimeoutId); //Both returning the timeout object created

timeoutCollection.getScheduled(); //Returns an array of timeout objects that have not yet executed
timeoutCollection.getCompleted(); //Returns an array of timeout objects that have been executed
timeoutCollection.getAll(); //Returns an array of timeout objects

timeoutCollection.remove(myTimeoutId);
timeoutCollection.removeAll();
```

Basically, you should inject the library script from in place you would like the collection to work on.

# Why?

JavaScript will not expose us a simple object or array to view and manage all of our current `time-events`.
This library exposes the timeouts and intervals in your current page. In addition, it makes
it possible to manage those `time-events` in `run-time`.

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