'use strict';

var react = require('react');

var usePrevious = function usePrevious(value) {
  var ref = react.useRef(value);
  react.useEffect(function () {
    ref.current = value;
  }, [value]);
  return ref.current;
};

module.exports = usePrevious;
//# sourceMappingURL=usePrevious.js.map
