jsonData method
Given a Future input
whose value is expected to be a string in JSON
form, return another future that parses the JSON into a usable format.
Implementation
Future<dynamic> jsonData(Future<String> input) {
return input.then((response) => json.decode(response));
}