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

Method destroy

packages/core/src/resource/resource.ts:415–428  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

413 }
414
415 destroy(): void {
416 this.destroyed = true;
417 this.unregisterOnDestroy();
418 this.effectRef.destroy();
419 this.abortInProgressLoad();
420
421 // Destroyed resources enter Idle state.
422 this.state.set({
423 extRequest: {request: undefined, reload: 0},
424 status: 'idle',
425 previousStatus: 'idle',
426 stream: undefined,
427 });
428 }
429
430 private async loadEffect(): Promise<void> {
431 const extRequest = this.extRequest();

Callers 1

constructorMethod · 0.95

Calls 3

abortInProgressLoadMethod · 0.95
destroyMethod · 0.65
setMethod · 0.65

Tested by

no test coverage detected