Юниверс DG SDK UI
v2.15.0

Функция useMemo

  • useMemo will only recompute the memoized value when one of the deps has changed.

    Usage note: if calling useMemo with a referentially stable function, also give it as the input in the second argument.

    function expensive () { ... }

    function Component () {
    const expensiveResult = useMemo(expensive, [expensive])
    return ...
    }

    Параметры типа

    • T

    Параметры

    Возвращает T