https://github.com/devnax/timer-action
https://github.com/devnax/timer-action
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/devnax/timer-action
- Owner: devnax
- License: mit
- Created: 2022-07-06T09:09:14.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2022-07-06T09:14:29.000Z (almost 4 years ago)
- Last Synced: 2025-02-25T00:45:00.792Z (over 1 year ago)
- Language: TypeScript
- Size: 119 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
> this is a very simple and tiny library. this can help you when you have multiple actions but you want to execute once then you can get benefit from this library.
> like you have a search box, you add a onchange event in the input element so when the input change, the event fired every time, and your action also fired. but you want to call your action after stop writing. then you can use it.
## Usages
```js
import timerAction from 'timer-action'
timerAction(key, callback, time)
```
### Arguments
> key: `string` - unique key
> > callback: `Function` - action callback
> > time: `number` set the duration in milliseconds