@vuesax-alpha/nightly
Version:
A Component Library for Vue 3
16 lines (13 loc) • 473 B
JavaScript
import { isNode, getNodeName } from '../../utils/dom.mjs';
function isComponentPublicInstance(target) {
return target != null && Object.prototype.hasOwnProperty.call(target, "$el");
}
function unwrapElement(target) {
if (isComponentPublicInstance(target)) {
const element = target.$el;
return isNode(element) && getNodeName(element) === "#comment" ? null : element;
}
return target;
}
export { unwrapElement };
//# sourceMappingURL=unwrap-element.mjs.map