throttleit

WebJar for throttleit

Лицензия

Лицензия

MIT
Группа

Группа

org.webjars.npm
Идентификатор

Идентификатор

throttleit
Последняя версия

Последняя версия

1.0.0
Дата

Дата

Тип

Тип

jar
Описание

Описание

throttleit
WebJar for throttleit
Ссылка на сайт

Ссылка на сайт

http://webjars.org
Система контроля версий

Система контроля версий

https://github.com/component/throttle

Скачать throttleit

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.webjars.npm/throttleit/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>throttleit</artifactId>
    <version>1.0.0</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/throttleit/
implementation 'org.webjars.npm:throttleit:1.0.0'
// https://jarcasting.com/artifacts/org.webjars.npm/throttleit/
implementation ("org.webjars.npm:throttleit:1.0.0")
'org.webjars.npm:throttleit:jar:1.0.0'
<dependency org="org.webjars.npm" name="throttleit" rev="1.0.0">
  <artifact name="throttleit" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='throttleit', version='1.0.0')
)
libraryDependencies += "org.webjars.npm" % "throttleit" % "1.0.0"
[org.webjars.npm/throttleit "1.0.0"]

Зависимости

Библиотека не имеет зависимостей. Это самодостаточное приложение, которое не зависит ни от каких других библиотек.

Модули Проекта

Данный проект не имеет модулей.

throttle

Throttle a function

Installation

$ component install component/throttle
$ npm install throttleit

Example

// with component:
var throttle = require('throttle');
// with npm: 
// var throttle = require('throttleit');

window.onresize = throttle(resize, 200);

function resize(e) {
  console.log('height', window.innerHeight);
  console.log('width', window.innerWidth);
}

API

throttle(fn, wait)

Creates a function that will call fn at most once every wait milliseconds.

Supports leading and trailing invocation.

fn will receive last context (this) and last arguments passed to a throttled wrapper before fn was invoked.

License

MIT

org.webjars.npm

Components

modular components for component

Версии библиотеки

Версия
1.0.0
0.0.2