@skt-t1-byungi/array-find-index

findIndex() for old browser, in typescript.

Usage no npm install needed!

<script type="module">
  import sktT1ByungiArrayFindIndex from 'https://cdn.skypack.dev/@skt-t1-byungi/array-find-index';
</script>

README

@skt-t1-byungi/array-find-index

findIndex() for old browser, in typescript.

Example

findIndex([1, 2, 3, 4], x => x % 2 === 0)
// => 1

findIndex(array, finder, [thisArg])

array

Target array.

finder

Function is a predicate, to test each element.

thisArg

Value to use as this when executing callback.

License

MIT