import 'package:http/http.dart';
void main() async {
String url =
'https://gist.githubusercontent.com/manfredow/5256b04d5363df2f1f5bc53b7bb8eeac/raw/813091934413fe20575f11233f32ad0c6b54a065/recipes.json';
var response = await get(Uri.parse(url));
print(response.body);
}
OPCAO 2;
import 'package:http/http.dart';
void main() {
requestsfuture();
}
requestsfuture() {
String url =
"https://gist.githubusercontent.com/manfredow/5256b04d5363df2f1f5bc53b7bb8eeac/raw/813091934413fe20575f11233f32ad0c6b54a065/recipes.json";
Future future_ = get(Uri.parse(url));
future_.then((value) {
print(value.body);
});
}