@mindfulness/utils
    Preparing search index...

    Function when

    • When something is defined, do something with it.

      Type Parameters

      • T
      • R

      Parameters

      • thing: Nullable<T>

        The thing to check

      • doWork: (inp: T) => R

        What to do if the thing is defined

      Returns Maybe<R>

      • returns undefined if "thing" is not defined or whatever is returned from doWork