Skip to content

Commit 3539c9f

Browse files
committed
New example.
1 parent feaaedf commit 3539c9f

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

waiting/index.js

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
require('total.js');
2+
3+
F.route('/', function() {
4+
this.plain('Welcome');
5+
});
6+
7+
F.wait('database');
8+
F.wait('users');
9+
F.wait('system');
10+
11+
setTimeout(function() {
12+
F.wait('database');
13+
}, 3000);
14+
15+
setTimeout(function() {
16+
F.wait('users');
17+
}, 5000);
18+
19+
setTimeout(function() {
20+
F.wait('system');
21+
}, 7000);
22+
23+
// Run the web server
24+
F.http('debug');
25+
26+
// Open browser with http://127.0.0.1:8000/ and refresh repeatly.

0 commit comments

Comments
 (0)