Skip to content

Commit

Permalink
rename bindMap to let
Browse files Browse the repository at this point in the history
  • Loading branch information
Punie authored and gcanti committed Sep 14, 2022
1 parent b3cd423 commit cd06390
Show file tree
Hide file tree
Showing 58 changed files with 529 additions and 431 deletions.
28 changes: 14 additions & 14 deletions docs/modules/Array.ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,6 @@ Added in v2.0.0
- [Spanned (interface)](#spanned-interface)
- [apS](#aps)
- [bind](#bind)
- [bindMap](#bindmap)
- [bindTo](#bindto)
- [deleteAt](#deleteat)
- [elem](#elem)
Expand All @@ -200,6 +199,7 @@ Added in v2.0.0
- [insertAt](#insertat)
- [intercalate](#intercalate)
- [isOutOfBound](#isoutofbound)
- [let](#let)
- [lookup](#lookup)
- [modifyAt](#modifyat)
- [size](#size)
Expand Down Expand Up @@ -3289,19 +3289,6 @@ export declare const bind: <N, A, B>(

Added in v2.8.0

## bindMap

**Signature**

```ts
export declare const bindMap: <N, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => (fa: A[]) => { readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }[]
```

Added in v2.13.0

## bindTo

**Signature**
Expand Down Expand Up @@ -3527,6 +3514,19 @@ assert.strictEqual(isOutOfBound(3, ['a', 'b', 'c']), true)

Added in v2.0.0

## let

**Signature**

```ts
export declare const let: <N, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => (fa: A[]) => { readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }[]
```

Added in v2.13.0

## lookup

This function provides a safe way to read a value at a particular index from an array.
Expand Down
28 changes: 14 additions & 14 deletions docs/modules/Either.ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,11 @@ Added in v2.0.0
- [apS](#aps)
- [apSW](#apsw)
- [bind](#bind)
- [bindMap](#bindmap)
- [bindTo](#bindto)
- [bindW](#bindw)
- [elem](#elem)
- [exists](#exists)
- [let](#let)
- [sequenceArray](#sequencearray)
- [toError](#toerror)
- [traverseArray](#traversearray)
Expand Down Expand Up @@ -1736,19 +1736,6 @@ export declare const bind: <N, A, E, B>(
Added in v2.8.0
## bindMap
**Signature**
```ts
export declare const bindMap: <N, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => <E>(fa: Either<E, A>) => Either<E, { readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }>
```
Added in v2.13.0
## bindTo
**Signature**
Expand Down Expand Up @@ -1813,6 +1800,19 @@ assert.strictEqual(gt2(right(3)), true)
Added in v2.0.0
## let
**Signature**
```ts
export declare const let: <N, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => <E>(fa: Either<E, A>) => Either<E, { readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }>
```
Added in v2.13.0
## sequenceArray
**Signature**
Expand Down
89 changes: 50 additions & 39 deletions docs/modules/Functor.ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,9 @@ Added in v2.0.0
- [Functor3C (interface)](#functor3c-interface)
- [Functor4 (interface)](#functor4-interface)
- [utils](#utils)
- [bindMap](#bindmap)
- [bindTo](#bindto)
- [let](#let)
- [let\_](#let_)
- [~~FunctorComposition11~~ (interface)](#functorcomposition11-interface)
- [~~FunctorComposition12C~~ (interface)](#functorcomposition12c-interface)
- [~~FunctorComposition12~~ (interface)](#functorcomposition12-interface)
Expand Down Expand Up @@ -219,50 +220,90 @@ Added in v2.0.0

# utils

## bindMap
## bindTo

**Signature**

```ts
export declare function bindTo<F extends URIS4>(
F: Functor4<F>
): <N extends string>(name: N) => <S, R, E, A>(fa: Kind4<F, S, R, E, A>) => Kind4<F, S, R, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS3>(
F: Functor3<F>
): <N extends string>(name: N) => <R, E, A>(fa: Kind3<F, R, E, A>) => Kind3<F, R, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS3, E>(
F: Functor3C<F, E>
): <N extends string>(name: N) => <R, A>(fa: Kind3<F, R, E, A>) => Kind3<F, R, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS2>(
F: Functor2<F>
): <N extends string>(name: N) => <E, A>(fa: Kind2<F, E, A>) => Kind2<F, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS2, E>(
F: Functor2C<F, E>
): <N extends string>(name: N) => <A>(fa: Kind2<F, E, A>) => Kind2<F, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS>(
F: Functor1<F>
): <N extends string>(name: N) => <A>(fa: Kind<F, A>) => Kind<F, { readonly [K in N]: A }>
export declare function bindTo<F>(
F: Functor<F>
): <N extends string>(name: N) => <A>(fa: HKT<F, A>) => HKT<F, { readonly [K in N]: A }>
```

Added in v2.10.0

## let

**Signature**

```ts
export declare const let: typeof let_
```

Added in v2.13.0

## let\_

**Signature**

```ts
export declare function bindMap<F extends URIS4>(
function let_<F extends URIS4>(
F: Functor4<F>
): <N extends string, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => <S, R, E>(
fa: Kind4<F, S, R, E, A>
) => Kind4<F, S, R, E, { readonly [K in keyof A | N]: K extends keyof A ? A[K] : B }>
export declare function bindMap<F extends URIS3>(
function let_<F extends URIS3>(
F: Functor3<F>
): <N extends string, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => <R, E>(fa: Kind3<F, R, E, A>) => Kind3<F, R, E, { readonly [K in keyof A | N]: K extends keyof A ? A[K] : B }>
export declare function bindMap<F extends URIS3, E>(
function let_<F extends URIS3, E>(
F: Functor3C<F, E>
): <N extends string, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => <R>(fa: Kind3<F, R, E, A>) => Kind3<F, R, E, { readonly [K in keyof A | N]: K extends keyof A ? A[K] : B }>
export declare function bindMap<F extends URIS2>(
function let_<F extends URIS2>(
F: Functor2<F>
): <N extends string, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => <E>(fa: Kind2<F, E, A>) => Kind2<F, E, { readonly [K in keyof A | N]: K extends keyof A ? A[K] : B }>
export declare function bindMap<F extends URIS2, E>(
function let_<F extends URIS2, E>(
F: Functor2C<F, E>
): <N extends string, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => (fa: Kind2<F, E, A>) => Kind2<F, E, { readonly [K in keyof A | N]: K extends keyof A ? A[K] : B }>
export declare function bindMap<F extends URIS>(
function let_<F extends URIS>(
F: Functor1<F>
): <N extends string, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => (fa: Kind<F, A>) => Kind<F, { readonly [K in keyof A | N]: K extends keyof A ? A[K] : B }>
export declare function bindMap<F>(
function let_<F>(
F: Functor<F>
): <N extends string, A, B>(
name: Exclude<N, keyof A>,
Expand All @@ -272,36 +313,6 @@ export declare function bindMap<F>(

Added in v2.13.0

## bindTo

**Signature**

```ts
export declare function bindTo<F extends URIS4>(
F: Functor4<F>
): <N extends string>(name: N) => <S, R, E, A>(fa: Kind4<F, S, R, E, A>) => Kind4<F, S, R, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS3>(
F: Functor3<F>
): <N extends string>(name: N) => <R, E, A>(fa: Kind3<F, R, E, A>) => Kind3<F, R, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS3, E>(
F: Functor3C<F, E>
): <N extends string>(name: N) => <R, A>(fa: Kind3<F, R, E, A>) => Kind3<F, R, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS2>(
F: Functor2<F>
): <N extends string>(name: N) => <E, A>(fa: Kind2<F, E, A>) => Kind2<F, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS2, E>(
F: Functor2C<F, E>
): <N extends string>(name: N) => <A>(fa: Kind2<F, E, A>) => Kind2<F, E, { readonly [K in N]: A }>
export declare function bindTo<F extends URIS>(
F: Functor1<F>
): <N extends string>(name: N) => <A>(fa: Kind<F, A>) => Kind<F, { readonly [K in N]: A }>
export declare function bindTo<F>(
F: Functor<F>
): <N extends string>(name: N) => <A>(fa: HKT<F, A>) => HKT<F, { readonly [K in N]: A }>
```

Added in v2.10.0

## ~~FunctorComposition11~~ (interface)

**Signature**
Expand Down
20 changes: 10 additions & 10 deletions docs/modules/IO.ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ Added in v2.0.0
- [Do](#do)
- [apS](#aps)
- [bind](#bind)
- [bindMap](#bindmap)
- [bindTo](#bindto)
- [let](#let)
- [sequenceArray](#sequencearray)
- [traverseArray](#traversearray)
- [traverseArrayWithIndex](#traversearraywithindex)
Expand Down Expand Up @@ -420,28 +420,28 @@ export declare const bind: <N, A, B>(
Added in v2.8.0
## bindMap
## bindTo
**Signature**
```ts
export declare const bindMap: <N, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => (fa: IO<A>) => IO<{ readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }>
export declare const bindTo: <N>(name: N) => <A>(fa: IO<A>) => IO<{ readonly [K in N]: A }>
```
Added in v2.13.0
Added in v2.8.0
## bindTo
## let
**Signature**
```ts
export declare const bindTo: <N>(name: N) => <A>(fa: IO<A>) => IO<{ readonly [K in N]: A }>
export declare const let: <N, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => (fa: IO<A>) => IO<{ readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }>
```
Added in v2.8.0
Added in v2.13.0
## sequenceArray
Expand Down
28 changes: 14 additions & 14 deletions docs/modules/IOEither.ts.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,11 +122,11 @@ Added in v2.0.0
- [apS](#aps)
- [apSW](#apsw)
- [bind](#bind)
- [bindMap](#bindmap)
- [bindTo](#bindto)
- [bindW](#bindw)
- [bracket](#bracket)
- [bracketW](#bracketw)
- [let](#let)
- [sequenceArray](#sequencearray)
- [sequenceSeqArray](#sequenceseqarray)
- [traverseArray](#traversearray)
Expand Down Expand Up @@ -1268,19 +1268,6 @@ export declare const bind: <N, A, E, B>(

Added in v2.8.0

## bindMap

**Signature**

```ts
export declare const bindMap: <N, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => <E>(fa: IOEither<E, A>) => IOEither<E, { readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }>
```

Added in v2.8.0

## bindTo

**Signature**
Expand Down Expand Up @@ -1343,6 +1330,19 @@ export declare const bracketW: <E1, A, E2, B, E3>(

Added in v2.12.0

## let

**Signature**

```ts
export declare const let: <N, A, B>(
name: Exclude<N, keyof A>,
f: (a: A) => B
) => <E>(fa: IOEither<E, A>) => IOEither<E, { readonly [K in N | keyof A]: K extends keyof A ? A[K] : B }>
```

Added in v2.13.0

## sequenceArray

**Signature**
Expand Down
Loading

0 comments on commit cd06390

Please sign in to comment.