http-server
http-server copied to clipboard
Can i deal with different path?
almost like nginx:
location / {
root 'index path'
}
location /static/ {
root 'static path'
}
or like http&express:
app.all('/static/*',function(req,res){
// do somthing
});
...
options:{
before:[beforeHandler]
}
...
function beforeHandler(req,res){
let path = req.url;
if(path === '/'){
// index
}
...
}
This issue has been inactive for 180 days
Duplicate of #139