"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.usePrevious = void 0;
var react_1 = require("react");
var usePrevious = function (value) {
    var valueHolderRef = (0, react_1.useRef)();
    (0, react_1.useEffect)(function () {
        valueHolderRef.current = value;
    }, [value]);
    return valueHolderRef.current;
};
exports.usePrevious = usePrevious;
