find-index

WebJar for find-index

Лицензия

Лицензия

MIT
Категории

Категории

Dex Универсальные библиотеки Utility
Группа

Группа

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

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

find-index
Последняя версия

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

1.1.1
Дата

Дата

Тип

Тип

jar
Описание

Описание

find-index
WebJar for find-index
Ссылка на сайт

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

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

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

https://github.com/jsdf/find-index

Скачать find-index

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

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

Зависимости

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

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

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

find-index

An implementation of the ES6 method Array.prototype.findIndex as a standalone module and a ponyfill.

Finds an item in an array matching a predicate function, and returns its index.

Fast both when thisArg is used and also when it isn't.

usage

npm install find-index
var findIndex = require('find-index/findIndex')
var findIndex = require('find-index/ponyfill') // will use native Array#findIndex if available.
var findLastIndex = require('find-index/findLastIndex') // search backwards from end
findIndex(array, callback[, thisArg])
findLastIndex(array, callback[, thisArg])
Parameters:
  array
    The array to operate on.
  callback
    Function to execute on each value in the array, taking three arguments:
      element
        The current element being processed in the array.
      index
        The index of the current element being processed in the array.
      array
        The array findIndex was called upon.
  thisArg
    Object to use as this when executing callback.

Based on array-findindex

performance

$ iojs --harmony_arrays perf/benchmark.js

native Array.prototype.findIndex: 6347ms
findIndex: 1633ms
findIndex ponyfill: 6384ms
findLastIndex: 1508ms
npm lodash.findindex: 2900ms
npm array-findindex: 3512ms

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

Версия
1.1.1
0.1.1