diff --git a/doc/api/globals.md b/doc/api/globals.md index a70442f1bb91ec..2beffb116ba681 100644 --- a/doc/api/globals.md +++ b/doc/api/globals.md @@ -41,14 +41,14 @@ changes: description: No longer experimental. --> -A utility class used to signal cancelation in selected `Promise`-based APIs. +A utility class used to signal cancellation in selected `Promise`-based APIs. The API is based on the Web API {AbortController}. ```js const ac = new AbortController(); ac.signal.addEventListener('abort', () => console.log('Aborted!'), - { once: true }); + { once: true }); ac.abort(); @@ -595,6 +595,54 @@ The following globals are available to use with `fetch`: * [`Request`][] * [`Response`][] +### Differences from the Fetch Standard + +Node.js's `fetch()` implementation, based on [undici](https://undici.nodejs.org), +has several intentional differences from the +[WHATWG Fetch Standard](https://fetch.spec.whatwg.org/): + +
new Response(asyncIterable)ReadableStream,
+BufferSource, Blob, FormData,
+URLSearchParams, USVString, or null as
+the Response body. Node.js extends this to also accept async
+iterables, enabling flexible streaming response construction.
+
+Host,
+Connection, Content-Length, User-Agent,
+Referer) from being set programmatically. Node.js removes these
+restrictions, giving users full control over request and response headers.
+
+