diff options
mascara - server - serve bundles from dist
Diffstat (limited to 'mascara/server')
-rw-r--r-- | mascara/server/index.js | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/mascara/server/index.js b/mascara/server/index.js index 2bc2441d0..2f3a7a5ff 100644 --- a/mascara/server/index.js +++ b/mascara/server/index.js @@ -9,23 +9,10 @@ module.exports = createMetamascaraServer function createMetamascaraServer () { - // start bundlers - const metamascaraBundle = createBundle(path.join(__dirname, '/../src/mascara.js')) - const proxyBundle = createBundle(path.join(__dirname, '/../src/proxy.js')) - const uiBundle = createBundle(path.join(__dirname, '/../src/ui.js')) - const backgroundBuild = createBundle(path.join(__dirname, '/../src/background.js')) - // setup server const server = express() server.use(compression()) - // serve bundles - serveBundle(server, '/metamascara.js', metamascaraBundle) - serveBundle(server, '/scripts/ui.js', uiBundle) - serveBundle(server, '/scripts/proxy.js', proxyBundle) - // the serviceworker must be served from the root of the app - serveBundle(server, '/background.js', backgroundBuild) - // serve assets server.use(express.static(path.join(__dirname, '/../ui/'), { setHeaders: (res) => res.set('X-Frame-Options', 'DENY') })) server.use(express.static(path.join(__dirname, '/../../dist/mascara'))) |