superjoe30/connect-proxy — pull request #6 by presidento (2013-02-23 00:04:06+00:00)
Title: Allow to set the route within options

Grunt initializes connect with [middlewares as function arguments](https://github.com/senchalabs/connect/blob/master/lib/connect.js#L71), therefore the only way to pass the route is to write it to the options.

With this patch you can add a `route` string to the option and it goes next if it is outside that.

```javascript
var proxyOptions = url.parse('http://localhost');
proxyOptions.route = '/api/';

var app = connect(proxy(proxyOptions));
```