const express = require('express'); const app = express(); const path = require('path'); const router = express.Router(); router.get('/',function(req,res){ res.sendFile(path.join(__dirname+'/page/index.html')); }); app.use(express.static('page')); app.use('/', router); app.listen(process.env.port || 8080); console.log('.');