From 6ef44b7883cd93920ba678ba0f6c6c5deeb224bf Mon Sep 17 00:00:00 2001 From: Daniel Lando Date: Tue, 1 Dec 2020 16:36:36 +0100 Subject: [PATCH] fix: broken page refresh 404 #42 --- app.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app.js b/app.js index f4fca76cb02..2cf87651c11 100644 --- a/app.js +++ b/app.js @@ -39,14 +39,16 @@ app.use( ) app.use(cookieParser()) +app.use(history({ + index: '/' +})) + app.get('/', renderIndex) app.use('/', express.static(utils.joinPath(false, 'dist'))) app.use(cors()) -app.use(history()) - function hasProperty (obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop) }