io_http 0.1.0 copy "io_http: ^0.1.0" to clipboard
io_http: ^0.1.0 copied to clipboard

outdated

A customized HttpClient based on the dart:io package.

example/main.dart

import 'package:io_http/io_http.dart';

void main(List<String> args) async {
  if (args == null || args.length < 2) {
    print('Usage: dart main.dart <URI> <HOST>');
    exit(1);
  }

  final uriArg = args[0];

  if (!uriArg.startsWith('https://')) {
    print('URI must start with https://');
    exit(1);
  }

  final uri = Uri.parse(uriArg);
  final host = args[1];
  final client = IoHttpClient();
  final req = await client.openUrl('get', uri, host);
  final resp = await req.close();
  print(resp.headers);
}
0
likes
0
pub points
3%
popularity

Publisher

verified publisherxinthink.com

A customized HttpClient based on the dart:io package.

Homepage
Repository (GitHub)
View/report issues

License

unknown (LICENSE)

More

Packages that depend on io_http