MCPcopy Create free account
hub / github.com/NativeScript/NativeScript / Response

Function Response

packages/core/fetch/index.mjs:402–414  ·  view source on GitHub ↗
(bodyInit, options)

Source from the content-addressed store, hash-verified

400 Body.call(Request.prototype);
401
402 function Response(bodyInit, options) {
403 if (!options) {
404 options = {};
405 }
406
407 this.type = "default";
408 this.status = options.status === undefined ? 200 : options.status;
409 this.ok = this.status >= 200 && this.status < 300;
410 this.statusText = "statusText" in options ? options.statusText : "OK";
411 this.headers = new Headers(options.headers);
412 this.url = options.url || "";
413 this._initBody(bodyInit);
414 }
415
416 Body.call(Response.prototype);
417

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected