Skip to content

Commit c68f1b9

Browse files
Simon Siegertmonkpow
authored andcommitted
Add js language to markdown for syntax highlighting (#385)
1 parent ad94d32 commit c68f1b9

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ If any Promise is rejected, ```next(x)``` is called in the hosting application,
3939

4040

4141
e.g.
42-
```
42+
```js
4343
app.use(proxy('/reject-promise', {
4444
proxyReqOptDecorator: function() {
4545
return Promise.reject('An arbitrary rejection message.');
@@ -49,23 +49,23 @@ e.g.
4949

5050
eventually calls
5151

52-
```
52+
```js
5353
next('An arbitrary rejection messasage');
5454
```
5555

5656
### Host
5757

5858
The first positional argument is for the proxy host; in many cases you will use a static string here, eg.
5959

60-
```
60+
```js
6161
app.use('/', proxy('http://google.com'))
6262
```
6363

6464
However, this argument can also be a function, and that function can be
6565
memoized or computed on each request, based on the setting of
6666
```memoizeHost```.
6767

68-
```
68+
```js
6969
function selectProxyHost() {
7070
return (new Date() % 2) ? 'http://google.com' : 'http://altavista.com';
7171
}

0 commit comments

Comments
 (0)