Skip to content

Commit 0023116

Browse files
committed
Pack send, show that PORT is configurable
1 parent abe957f commit 0023116

File tree

2 files changed

+5
-15
lines changed

2 files changed

+5
-15
lines changed

_tests/README.md

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,8 @@ node _tests/cli.js -f strtotime
88

99
# Web
1010

11-
```html
12-
<script src="http://code.jquery.com/jquery-1.9.1.min.js"></script>
13-
<script src="phpjsutil.js"></script>
14-
<script type="text/javascript">
15-
// Get `code`
16-
PhpjsUtil.parse(code, function (err, result) {
17-
if (err) {
18-
$('#content').append('<pre class="alert-warning alert">' + JSON.stringify(err, undefined, 2) + '</pre>');
19-
}
20-
$('#content').append('<pre>' + JSON.stringify(result, undefined, 2) + '</pre>');
21-
22-
console.log(result);
23-
});
24-
</script>
11+
```bash
12+
PORT=8080 node _tests/server.js
2513
```
2614

15+
Point your webbrowser to http://localhost:8080

_tests/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@
99
},
1010
"dependencies": {
1111
"cli": "~0.4.4-2",
12-
"glob": "~3.2.1"
12+
"glob": "~3.2.1",
13+
"send": "~0.1.0"
1314
},
1415
"keywords": [
1516
"cli",

0 commit comments

Comments
 (0)