"use strict";
Object.defineProperty(exports, "__esModule", {
    value: true
});
Object.defineProperty(exports, "default", {
    enumerable: true,
    get: function() {
        return useRefs;
    }
});
var _interop_require_default = require("@swc/helpers/_/_interop_require_default");
var _react = /*#__PURE__*/ _interop_require_default._(require("react"));
function useRefs() {
    var refs = _react.default.useRef([]);
    var setRefs = _react.default.useCallback(function(index) {
        return function(el) {
            if (el) refs.current[index] = el;
        };
    }, []);
    var reset = _react.default.useCallback(function() {
        refs.current = [];
    }, []);
    return [
        refs.current,
        setRefs,
        reset
    ];
}
