Response()
The Response()
constructor creates a new Response
object.
Syntax
new Response()
new Response(body)
new Response(body, options)
Parameters
body
optional: An object defining a body for the response. This can be
null
(which is the default value), or one of:ArrayBuffer
TypedArray
DataView
ReadableStream
URLSearchParams
String
- string literal
options
optional: An options object containing any custom settings that you want to apply to the response, or an empty object (which is the default value). The possible options are: