"use strict";
const React = require("react");
const usePrevious = (value, defaultValue) => {
  const ref = React.useRef(defaultValue);
  React.useEffect(() => {
    ref.current = value;
  });
  return ref.current;
};
module.exports = usePrevious;
