1.0.11 • Published 7 years ago

http-server-dev v1.0.11

Weekly downloads
1
License
ISC
Repository
github
Last release
7 years ago

http-server-dev

基于nodejs实现的http服务器,用于开发环境,支持反向代理

#Why 做单页面应候需要搭建http服务器,之前一直用grunt,gulp的http插件,后来有了webpack,基本不用grunt,gulp这些工具,转向npm script,为了开发便利,基于express开发了这款http服务器,方便大家使用!

#Install npm install http-server-dev

#Command

npm install -g http-server-dev   
http-server-dev

#Script Usage:

server = require('http-server-dev')   
server(option, callback)  

##option

var config = {
    hostname : '0.0.0.0',
    port: '80',
    webPath: [__dirname],
    proxies:{
        '/speapi':{
            host: 'api.demo.com',
            headers:{
                host: 'api.demo.com'
            }
        }
    }
}
1.0.11

7 years ago

1.0.10

7 years ago

1.0.9

8 years ago

1.0.8

8 years ago

1.0.7

8 years ago

1.0.6

8 years ago

1.0.5

8 years ago

1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago