forked from michaeloryl/angular2-bootstrap4-oauth2-webpack
-
Notifications
You must be signed in to change notification settings - Fork 0
/
server.js
22 lines (16 loc) · 728 Bytes
/
server.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
var express = require('express');
var livereload = require('livereload');
var app = express();
app.use('/node_modules', express.static(__dirname + '/node_modules'));
app.use('/__build__', express.static(__dirname + '/__build__'));
app.use('/', express.static(__dirname + '/src'));
/* If using HTML5 style URLs in the client app, you'll need dummy URL support here for your routes */
//app.use('/public', express.static(__dirname + '/src'));
//app.use('/protected', express.static(__dirname + '/src'));
app.listen(3000);
console.log('Listening on port 3000.');
app = livereload.createServer({
exts: ['html', 'css', 'js', 'png', 'gif', 'jpg', 'ts']
});
app.watch(__dirname + '/src');
console.log('Live reload enabled');