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

Method constructor

adev/src/app/features/tutorial/tutorial.component.ts:111–138  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

109 readonly answerRevealed = signal<boolean>(false);
110
111 constructor() {
112 effect(() => {
113 const tutorialData = this.tutorialData();
114 const path = this.path();
115 const label = this.label();
116 const parent = this.parent();
117 if (!tutorialData || !path || !label) {
118 return;
119 }
120 untracked(() => this.setTutorialData({path, label, parent, tutorialData}));
121 });
122
123 const destroyRef = inject(DestroyRef);
124 afterNextRender(() => {
125 this.splitResizerHandler.init(
126 this.elementRef,
127 this.content()!,
128 this.resizer(),
129 this.editor(),
130 );
131
132 from(this.loadEmbeddedEditorComponent())
133 .pipe(takeUntilDestroyed(destroyRef))
134 .subscribe((editorComponent) => {
135 this.embeddedEditorComponent.set(editorComponent);
136 });
137 });
138 }
139
140 toggleNavigationDropdown($event: MouseEvent): void {
141 // Stop propagation required to avoid detecting click inside ClickOutside

Callers

nothing calls this directly

Calls 14

setTutorialDataMethod · 0.95
effectFunction · 0.90
untrackedFunction · 0.90
injectFunction · 0.90
afterNextRenderFunction · 0.90
takeUntilDestroyedFunction · 0.90
labelMethod · 0.80
contentMethod · 0.80
initMethod · 0.65
subscribeMethod · 0.65
setMethod · 0.65

Tested by

no test coverage detected