iterable overview
Added in v0.12.0
Table of contents
- Apply
- Chain
- Combinators
- Constructors
- Eq
- Functor
- Instances
- Iteratable
- Model
- NaturalTransformation
- Pointed
- Takeable
- Unfoldable
Apply
ap
Signature
export declare const ap: <A1>(fa: Iterable<A1>) => <A2>(fab: Iterable<(a: A1) => A2>) => Iterable<A2>
apFirst
Signature
export declare const apFirst: <B>(second: Iterable<B>) => <A>(first: Iterable<A>) => Iterable<A>
apS
Signature
export declare const apS: <N, A, B>(
name: Exclude<N, keyof A>,
fb: Iterable<B>
) => (fa: Iterable<A>) => Iterable<{ readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }>
apSecond
Signature
export declare const apSecond: <B>(second: Iterable<B>) => <A>(first: Iterable<A>) => Iterable<B>
Chain
bind
Signature
export declare const bind: <N, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => Iterable<B>
) => (ma: Iterable<A>) => Iterable<{ readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }>
chain
Signature
export declare const chain: <A1, A2>(f: (a: A1) => Iterable<A2>) => (fa: Iterable<A1>) => Iterable<A2>
chainFirst
Signature
export declare const chainFirst: <A, B>(f: (a: A) => Iterable<B>) => (first: Iterable<A>) => Iterable<A>
flatten
Signature
export declare const flatten: <A1>(fa: Iterable<Iterable<A1>>) => Iterable<A1>
Combinators
dropLeft
Signature
export declare const dropLeft: (count: number) => <A1>(fa: Iterable<A1>) => Iterable<A1>
dropLeftWhile
Signature
export declare const dropLeftWhile: <A1, A2 extends A1>(
f: Predicate<A1> | Refinement<A1, A2>
) => (fa: Iterable<A1>) => Iterable<A1>
dropLeftWhileMap
Signature
export declare const dropLeftWhileMap: <A, B>(f: (a: A) => option.Option<B>) => (fa: Iterable<A>) => Iterable<A>
dropLeftWhileMapWithIndex
Signature
export declare const dropLeftWhileMapWithIndex: <A1, A2>(
f: (i: number, a: A1) => option.Option<A2>
) => (fa: Iterable<A1>) => Iterable<A2>
dropLeftWhileWithIndex
Signature
export declare const dropLeftWhileWithIndex: <A1, A2 extends A1>(
f: PredicateWithIndex<number, A1> | RefinementWithIndex<number, A1, A2>
) => (fa: Iterable<A1>) => Iterable<A1>
dropRight
Signature
export declare const dropRight: (count: number) => <A1>(fa: Iterable<A1>) => Iterable<A1>
dropRightWhileMap
Signature
export declare const dropRightWhileMap: <A1, A2>(f: (a: A1) => option.Option<A2>) => (fa: Iterable<A1>) => Iterable<A1>
dropRightWhileMapWithIndex
Signature
export declare const dropRightWhileMapWithIndex: <A1, A2>(
f: (i: number, a: A1) => option.Option<A2>
) => (fa: Iterable<A1>) => Iterable<A1>
dropRightWhileWithIndex
Signature
export declare const dropRightWhileWithIndex: <A1, A2 extends A1>(
f: PredicateWithIndex<number, A1> | RefinementWithIndex<number, A1, A2>
) => (fa: Iterable<A1>) => Iterable<A1>
Constructors
iterate
Signature
export declare const iterate: <A>(f: Endomorphism<A>) => (a: A) => Iterable<A>
iterateWhileMapWithIndex
Signature
export declare const iterateWhileMapWithIndex: <A>(f: (i: number, a: A) => option.Option<A>) => (a: A) => Iterable<A>
Eq
getEq
Signature
export declare const getEq: <A>(eqa: eq.Eq<A>) => eq.Eq<Iterable<A>>
Functor
bindTo
Signature
export declare const bindTo: <N>(name: N) => <A>(fa: Iterable<A>) => Iterable<{ readonly [K in N]: A }>
flap
Signature
export declare const flap: <A>(a: A) => <B>(fab: Iterable<(a: A) => B>) => Iterable<B>
map
Signature
export declare const map: <A1, A2>(f: (a: A1) => A2) => (fa: Iterable<A1>) => Iterable<A2>
mapWithIndex
Signature
export declare const mapWithIndex: <A1, A2>(f: (index: number, a: A1) => A2) => (fa: Iterable<A1>) => Iterable<A2>
Instances
Applicative
Signature
export declare const Applicative: Applicative1<'Iterable'>
Apply
Signature
export declare const Apply: apply.Apply1<'Iterable'>
Chain
Signature
export declare const Chain: chain_.Chain1<'Iterable'>
DroppableLeft
Signature
export declare const DroppableLeft: Droppable1<'Iterable'>
DroppableLeftWithIndex
Signature
export declare const DroppableLeftWithIndex: DroppableWithIndex1<'Iterable', number>
Functor
Signature
export declare const Functor: functor.Functor1<'Iterable'>
FunctorWithIndex
Signature
export declare const FunctorWithIndex: FunctorWithIndex1<'Iterable', number>
Iteratable
Signature
export declare const Iteratable: iteratable.Iteratable1<'Iterable'>
IteratableWithIndex
Signature
export declare const IteratableWithIndex: iteratableWithIndex.IteratableWithIndex1<'Iterable', number>
Monad
Signature
export declare const Monad: Monad1<'Iterable'>
Unfoldable
Signature
export declare const Unfoldable: Unfoldable1<'Iterable'>
Iteratable
iterateWhileMap
Signature
export declare const iterateWhileMap: <A>(f: (a: A) => option.Option<A>) => (a: A) => Iterable<A>
Model
URI
Signature
export declare const URI: 'Iterable'
Added in v0.12.0
URI (type alias)
Signature
export type URI = typeof URI
Added in v0.12.0
NaturalTransformation
FromReadonlyArray
Signature
export declare const FromReadonlyArray: NaturalTransformation11<'ReadonlyArray', 'Iterable'>
ToReadonlyArray
Signature
export declare const ToReadonlyArray: NaturalTransformation11<'Iterable', 'ReadonlyArray'>
Pointed
Do
Signature
export declare const Do: Iterable<{}>
Pointed
Signature
export declare const Pointed: Pointed1<'Iterable'>
of
Signature
export declare const of: <A>(a: A) => Iterable<A>
Takeable
takeLeft
Signature
export declare const takeLeft: (count: number) => <A>(fa: Iterable<A>) => Iterable<A>
Unfoldable
unfold
Signature
export declare const unfold: <A, B>(b: B, f: (b: B) => option.Option<[A, B]>) => Iterable<A>