@adobe/data - v0.10.30
    Preparing search index...

    Function cached

    • Returns a function with the same signature as the factory, caching its result per object. Uses the same cache as getCached, so values are shared when the same factory is used.

      Type Parameters

      • A extends object
      • B

      Parameters

      • factory: (obj: A) => B

        A function that creates the value to be cached

      Returns (obj: A) => B

      A function that returns the cached value or a newly created value from the factory