@nx-js/limiters

Limiters for the NX compiler util.

Stats

stars 🌟issues ⚠️updated 🛠created 🐣size 🏋️‍♀️
00Jan 9, 2017Dec 31, 2016Minified + gzip package size for @nx-js/limiters in KB

Readme

Limiters

This repository contains a collection of rate limiters for the compiler utility. It creates an registers the following limiters.

  • if: Has one parameter. If the parameter is falsy, the event handler won't be called.
  • delay: Has a number parameter and delays the event handler by that many milliseconds. The delay is 200 milliseconds by default.
  • debounce: Has a number parameter and causes the event handler to only execute, if the event doesn't happen for at least that many milliseconds. The parameter is 200 milliseconds by default.
  • throttle: Has a number parameter and causes the event handler to execute only if it didn't execute in the last interval. The parameter is 200 - milliseconds by default.
  • key: Only handles the event if it matches with one of the keys provided as arguments. If the event is not a keyboard event, this limiter has no effect. For the name of special keys see this page.

You can learn more about NX rate limiters here.

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.