"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.getGhost = void 0;
const DATA_ATTRIBUTE = 'data-ghost';
const getGhost = function () {
  let el = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
  const [child] = el.querySelectorAll ? el.querySelectorAll("[".concat(DATA_ATTRIBUTE, "]")) : [];
  let ghost;
  if (child) {
    child.removeAttribute(DATA_ATTRIBUTE);
    ghost = child;
    child.remove();
  }
  return ghost;
};
exports.getGhost = getGhost;
//# sourceMappingURL=getGhost.js.map