4.0.0 • Published 6 years ago

starry.find v4.0.0

Weekly downloads
2
License
MIT
Repository
github
Last release
6 years ago

Member of the starry suite—modular functions for iterable objects.

npm node

Status

Applies to the whole suite.

Build Status Coverage Status

Usage

function find<T = any>(
  iterable: Iterable<T>,
  predicate: (item: T) => boolean
  )

Returns the first element in the iterable that satisfies the predicate.

Returns undefined if no element satisfies the predicate.

Parameters:

  • iterable: Iterable<T>
  • predicate: (T) => boolean

Returns: T | undefined

4.0.0

6 years ago

3.0.0

7 years ago

3.0.0-1

7 years ago

3.0.0-0

7 years ago

2.0.0

7 years ago

2.0.0-0

7 years ago

1.6.1

7 years ago

1.4.1

7 years ago

1.3.0

8 years ago

1.1.1

8 years ago

1.1.0

8 years ago