enable html history mode

This commit is contained in:
2019-07-01 21:38:18 +02:00
parent e484c4d732
commit 7121f71700

View File

@@ -57,8 +57,12 @@ function objectIdFromDate(date) {
function dateFromObjectId(objectId) { function dateFromObjectId(objectId) {
return Math.floor(mongo.ObjectId(objectId).getTimestamp().getTime() / 1000) return Math.floor(mongo.ObjectId(objectId).getTimestamp().getTime() / 1000)
}; }
app.use(express.static(path.join(__dirname, '../dist'))) app.use(express.static(path.join(__dirname, '../dist')))
app.get('/*', function(req, res) {
res.sendFile(path.join(__dirname, '../dist/index.html'))
})
module.exports = app module.exports = app