• Overview
@angular/core

RESPONSE_INIT

constant

Injection token for response initialization options.

API

  
    const RESPONSE_INIT: InjectionToken<ResponseInit | null>;
  
  

Description

Injection token for response initialization options.

Use this token to provide response options for configuring or initializing HTTP responses in server-side rendering or API endpoints.

Usage Notes

This token may be null in the following scenarios:

  • During the build processes.
  • When the application is rendered in the browser (client-side rendering).
  • When performing static site generation (SSG).
  • During route extraction in development (at the time of the request).
Jump to details