UNPKG
bd-static
Version:
latest (0.1.1)
0.1.1
0.1.0
bd.js static middleware
github.com/bdjs/bd-static
bdjs/bd-static
bd-static
/
example
/
index.js
18 lines
(12 loc)
•
269 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/** * bd-static - index.js * Created by mds on 15/6/2. */
'use strict'
;
var
koa =
require
(
'koa'
);
var
serve =
require
(
'../'
);
var
app =
koa
(); app.
use
(
serve
(
'public'
)); app.
use
(
serve
(
'public2'
,
'public2'
)); app.
use
(
serve
(
'public'
,
'public'
)); app.
listen
(
3333
);