UNPKG

@joist/element

Version:

Intelligently apply styles to WebComponents

12 lines 424 B
import { metadataStore } from "./metadata.js"; export function attrChanged(...names) { return function attrChangedDecorator(cb, ctx) { const meta = metadataStore.read(ctx.metadata); for (const name of names) { const val = meta.attrChanges.get(name) ?? new Set(); val.add(cb); meta.attrChanges.set(name, val); } }; } //# sourceMappingURL=attr-changed.js.map