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

Method ngOnInit

src/material/select/select.ts:629–641  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

627 }
628
629 ngOnInit() {
630 this._selectionModel = new SelectionModel<MatOption>(this.multiple);
631 this.stateChanges.next();
632 this._viewportRuler
633 .change()
634 .pipe(takeUntil(this._destroy))
635 .subscribe(() => {
636 if (this.panelOpen) {
637 this._overlayWidth = this._getOverlayWidth(this._preferredOverlayOrigin);
638 this._changeDetectorRef.detectChanges();
639 }
640 });
641 }
642
643 ngAfterContentInit() {
644 this._initialized.next();

Callers

nothing calls this directly

Calls 3

_getOverlayWidthMethod · 0.95
changeMethod · 0.80
nextMethod · 0.45

Tested by

no test coverage detected