text method

Future<String> text()

Returns a promise that resolves with a text representation of the response body.

MDN Reference

Implementation

Future<String> text() => blob().then((blob) => blob.text());