import { useState as r, useRef as u, useEffect as f } from "react";
const b = ({ attribute: i }) => {
  const [l, t] = r(!1), n = u(null);
  return f(() => {
    const e = n.current, s = e == null ? void 0 : e.nextElementSibling;
    s && s.getAttribute(i) === "true" ? t(!0) : t(!1);
  }, []), {
    ref: n,
    hasSiblingElement: l
  };
};
export {
  b as useHasNextSiblingByAttribute
};
