onrails
    Preparing search index...
    • flatMap(fromNullable(value), fn) — lift a nullable then bind through a Maybe-returning step. Convenient for chaining lookups.

      Type Parameters

      • T
      • U

      Parameters

      • value: T | null | undefined
      • fn: (value: T) => Maybe<U>

      Returns Maybe<U>

      optional(rawId, (id) => fromNullable(cache.get(id)));