@mikuroxina/mini-fn
    Preparing search index...

    Namespace Reader

    This package provides methods for a computation which allows reading external records.

    A Reader<R, A> object represents a computation, reading R and returning A:

    type Reader<R, A> = (record: R) => A;
    // Note that the actual code is defined as a special case of `ReaderT`.

    And you can work with it by the following methods:

    • withReader - Constructs a new Reader from your computation.
    • ask - Makes a pure computation reading the record.
    • compose - Composes two Readers.
    • local - Localizes record to be read.
    • run - Runs a computation with specified records.
    • weaken - Makes the record type weaker for application.
    • Monad operations:

    Moreover a ReaderT<R, M, A> monad transformer is the generalized version of Reader<R, A>. It accepts not A, but object on monad M.

    Interfaces

    ReaderHkt
    ReaderTHkt

    Type Aliases

    Reader
    ReaderT

    Variables

    profunctor

    Functions

    applicative
    applicativeT
    apply
    applyT
    applyWeak
    ask
    askM
    compose
    diMap
    flatMap
    flatMapT
    flatMapWeak
    flatten
    flattenWeak
    functor
    functorT
    local
    map
    mapReaderT
    mapT
    monad
    monadT
    product
    pure
    pureT
    run
    weaken
    withReader
    withReaderT