aboutsummaryrefslogtreecommitdiff
path: root/routes/manifest.js
diff options
context:
space:
mode:
Diffstat (limited to 'routes/manifest.js')
-rw-r--r--routes/manifest.js18
1 files changed, 18 insertions, 0 deletions
diff --git a/routes/manifest.js b/routes/manifest.js
new file mode 100644
index 0000000..377b7be
--- /dev/null
+++ b/routes/manifest.js
@@ -0,0 +1,18 @@
+'use strict'
+
+const express = require('express')
+const router = express.Router()
+
+router.get('/', function (req, res, next) {
+ console.log('got a request')
+
+ const isBeta = process.env.BETA === '1'
+
+ if (isBeta) {
+ res.sendFile('manifest.beta.webmanifest', { root: './public' })
+ } else {
+ res.sendFile('manifest.webmanifest', { root: './public' })
+ }
+})
+
+module.exports = router