-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.js
42 lines (28 loc) · 995 Bytes
/
index.js
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
42
const express = require('express');
const app = express();
const https = require("https");
const router = express.Router({strict: true})
let hbs = require('hbs')
app.set('view engine', 'hbs')
let path = require('path')
app.use(express.static(path.join(__dirname,'static')))
app.get('/', (req, res) => {
res.render("home_page")
})
const load_data = require('./scripts/load_data.js')
app.use(load_data.router)
const seeded_random = require('./scripts/seeded_random')
app.use(seeded_random.router)
const map = require('./scripts/map.js')
app.use(map)
const shop = require('./scripts/shop.js')
app.use(shop)
const transparency_index = require('./scripts/transparency_index.js')
app.use(transparency_index)
const test = require('./scripts/test.js')
app.use(test)
const sustainable = require('./scripts/sustainable.js')
app.use(sustainable)
let listener = app.listen(process.env.PORT || 8080, process.env.HOST || "0.0.0.0", function() {
console.log("Express server started");
});