Body

HTTP~ Body

A wrapper around a request/response HTTP body.

Constructor

new Body()

Source:

Methods

(async) json() → {Promise.<Object>}

Formats the body to an actual JSON object.

Source:
Returns:
Type:
Promise.<Object>

The complete body as a JavaScript object.

(async) text() → {Promise.<string>}

Formats the body to a UTF-8 string.

Source:
Returns:
Type:
Promise.<string>

The complete body as a UTF-8 string.