import { useLayoutEffect, useMemo } from "react";
export default (function () {
  var el = useMemo(function () {
    var div = document.createElement("div");
    document.body.append(div);
    return div;
  }, []);
  useLayoutEffect(function () {
    return function () {
      try {
        document.body.removeChild(el);
      } catch (e) {
        // Do nothing
      }
    };
  }, []);
  return el;
});