import 'package:dio/dio.dart';
void getHttp() async {
try {
Response response = await Dio().get("https://www.baidu.com");
print(response);
print("-------------");
print(response.data.toString());
} catch (e) {
print(e);
}
}
void main(List<String> args) {
getHttp();
}
网友评论