import { useState as r, useCallback as t } from "react";
const i = (l = !1) => {
  const [n, e] = r(l), u = t((s) => {
    e((f) => {
      const o = !f;
      return typeof s == "function" && s(o), o;
    });
  }, []), a = t(() => e(!0), []), c = t(() => e(!1), []);
  return {
    isToggled: n,
    toggle: u,
    enable: a,
    disable: c
  };
};
export {
  i as default
};
//# sourceMappingURL=useToggle.js.map
