UNPKG

@opensig/opendesign

Version:

20 lines (19 loc) 458 B
"use strict"; Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" }); function useElementDirective(onElementChange) { const directive = { mounted(el) { onElementChange(el, "mounted"); }, updated(el) { onElementChange(el, "updated"); }, unmounted() { onElementChange(null, "unmounted"); } }; return { getElementDirective: directive }; } exports.useElementDirective = useElementDirective;