akameco / key-locker

Locker

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

key-locker

Build Status Coverage Status tested with jest styled with prettier All Contributors

Locker

Install

$ npm install key-locker

Usage

const KeyLocker = require('key-locker');

const locker = keyLocker();

locker.add('test')
locker.has('test'))
// => true
// 1000ms later
locker.has('test'))
// => false

API

KeyLocker({ waitTime })

waitTime

Type: number
Default: 1000ms

refresh time.

Contributors

Thanks goes to these wonderful people (emoji key):


akameco

💻 📖 ⚠️ 🚇

This project follows the all-contributors specification. Contributions of any kind welcome!

License

MIT © akameco

About

Locker

License:MIT License


Languages

Language:JavaScript 100.0%