UNPKG

684 BJavaScriptView Raw
1/**
2 * Created by r9luox on 2016/8/17.
3 * 静态服务器的一些配置
4 */
5
6exports.servers = {
7 host: '127.0.0.1',
8 port: 3200, // http/https server port
9 sport: parseInt(Math.random() * 100 + 10000), // websocket server port
10 liveDelay: 2000
11};
12
13//目录默认索引文件
14exports.indexFile = {
15 file: 'index.html'
16};
17
18//缓存控制
19exports.Expires = {
20 fileMatch: /^(gif|png|jpg|js|css)$/ig,
21 maxAge: 60 * 60 * 24 * 365
22};
23
24//图片
25exports.Images = {
26 match: /gif|jpg|jpe|jpeg|png|ief|jfif|svg|ico/gi
27};
28
29//gzip压缩
30exports.Gzip = {
31 match: /css|js|html/ig
32};
33
34exports.liveReload = {
35 match: /html|text/gi
36};