MCPcopy Create free account
hub / github.com/angular/components / constructor

Method constructor

src/aria/combobox/combobox-widget.ts:43–57  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

41 private _observer: MutationObserver | undefined;
42
43 constructor() {
44 const el = this.element;
45 this._observer = new MutationObserver(mutations => {
46 for (const mutation of mutations) {
47 if (mutation.attributeName === 'id') {
48 this.popupId.set(el.id);
49 }
50 }
51 });
52
53 this._observer.observe(el, {
54 attributes: true,
55 attributeFilter: ['id'],
56 });
57 }
58
59 ngOnInit() {
60 this.popupId.set(this.element.id);

Callers

nothing calls this directly

Calls 2

setMethod · 0.80
observeMethod · 0.45

Tested by

no test coverage detected