MCPcopy
hub / github.com/mdn/web-components-examples / attributeChangedCallback

Method attributeChangedCallback

life-cycle-callbacks/main.js:34–37  ·  view source on GitHub ↗
(name, oldValue, newValue)

Source from the content-addressed store, hash-verified

32 }
33
34 attributeChangedCallback(name, oldValue, newValue) {
35 console.log("Custom square element attributes changed.");
36 updateStyle(this);
37 }
38}
39
40customElements.define("custom-square", Square);

Callers

nothing calls this directly

Calls 1

updateStyleFunction · 0.85

Tested by

no test coverage detected