-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathserver.js
More file actions
41 lines (31 loc) · 1001 Bytes
/
server.js
File metadata and controls
41 lines (31 loc) · 1001 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
var path = require('path');
var express = require('express');
var app = express();
app.use(express.static('docs'));
app.get('/events', function(req, res) {
res.sendFile(path.join(__dirname + '/docs/events.html'));
});
app.get('/about', function(req, res) {
res.sendFile(path.join(__dirname + '/docs/about.html'));
});
app.get('/team', function(req, res) {
res.sendFile(path.join(__dirname + '/docs/team.html'));
});
app.get('/apply', function(req, res) {
res.sendFile(path.join(__dirname + '/docs/apply.html'));
});
app.get('/join', function(req, res) {
res.sendFile(path.join(__dirname + '/docs/join.html'));
});
app.get('/contact', function(req, res) {
res.sendFile(path.join(__dirname + '/docs/contact.html'));
});
app.get('/contact', function(req, res) {
res.sendFile(path.join(__dirname + '/docs/contact.html'));
});
app.get('*', function(req, res){
res.sendFile(path.join(__dirname + '/docs/404.html'));
});
app.listen(3000, function() {
console.log('listening');
});