mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
docs: clarify behavior of credentials option during SSR on Node.js
This commit is contained in:
committed by
Alex Rickabaugh
parent
3d09713386
commit
90ac011fa9
@@ -531,6 +531,8 @@ Available `credentials` values:
|
||||
|
||||
TIP: Use `credentials: 'include'` when you need to send authentication cookies or headers to a different domain that supports CORS. Avoid mixing `credentials` and `withCredentials` options to prevent confusion.
|
||||
|
||||
IMPORTANT: During SSR on Node.js, `credentials: 'include'` does not automatically forward cookies from the incoming browser request. The `credentials` option does not remove `Cookie` or `Authorization` headers that you add explicitly. [Undici permits some headers that browsers forbid](https://undici.nodejs.org/#forbidden-and-safelisted-header-names), so only forward credential headers to trusted origins.
|
||||
|
||||
#### Referrer
|
||||
|
||||
The `referrer` option allows you to control what referrer information is sent with the request. This is important for privacy and security considerations.
|
||||
|
||||
Reference in New Issue
Block a user