commit | f1979e721b4b28256927eb7e3871bf0312c5011d | [log] [tgz] |
---|---|---|
author | Kevin Moore <kevmoo@google.com> | Thu Jul 18 09:48:30 2019 -0700 |
committer | Kevin Moore <kevmoo@users.noreply.github.com> | Thu Jul 18 09:57:33 2019 -0700 |
tree | 1da16cf886c316bce5b54aa20746a198bbeb639b | |
parent | 5e500d75329d638e6c683be6798fba4bb49c96d9 [diff] |
Fix URLs in readme
shelf_proxy
is a Shelf handler that proxies requests to an external server. It can be served directly and used as a proxy server, or it can be mounted within a larger application to proxy only certain URLs.
import 'package:shelf/shelf_io.dart' as shelf_io; import 'package:shelf_proxy/shelf_proxy.dart'; void main() { shelf_io.serve(proxyHandler("https://www.dartlang.org"), 'localhost', 8080) .then((server) { print('Proxying at http://${server.address.host}:${server.port}'); }); }