MCPcopy Index your code
hub / github.com/angular/angular / SimpleComponent

Class SimpleComponent

packages/platform-server/test/incremental_hydration_spec.ts:137–169  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

135 class DepB {}
136
137 @Component({
138 selector: 'app',
139 imports: [DepB],
140 template: `
141 <main (click)="fnA()">
142 @defer (on viewport; hydrate on interaction) {
143 <div (click)="fnA()">
144 Main defer block rendered!
145 @if (visible) {
146 Defer events work!
147 }
148 <div id="outer-trigger" (mouseover)="showMessage()"></div>
149 @defer (on viewport; hydrate on interaction) {
150 <p (click)="fnA()">Nested defer block</p>
151 <dep-b />
152 } @placeholder {
153 <span>Inner block placeholder</span>
154 }
155 </div>
156 } @placeholder {
157 <span>Outer block placeholder</span>
158 }
159 </main>
160 `,
161 })
162 class SimpleComponent {
163 items = [1, 2, 3];
164 visible = false;
165 fnA() {}
166 showMessage() {
167 this.visible = true;
168 }
169 }
170
171 const appId = 'custom-app-id';
172 const providers = [{provide: APP_ID, useValue: appId}];

Callers

nothing calls this directly

Calls 4

ComponentInterface · 0.90
signalFunction · 0.90
injectFunction · 0.90
isPlatformServerFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…