index : btroops | |
Virtual board game-aid for BattleTroops, an infantry combat simulator wargame published by FASA in 1989. |
aboutsummaryrefslogtreecommitdiff |
path: root/dev-server.cjs
diff options
author | Catalin Mititiuc <webdevcat@proton.me> | 2024-05-02 09:40:05 -0700 |
---|---|---|
committer | Catalin Mititiuc <webdevcat@proton.me> | 2024-05-02 10:05:50 -0700 |
commit | d2c218f72d1ad5bd65407433a51688b0a9bd0d89 (patch) | |
tree | d3de1fe656a7e193dc21a2c46c62e10f2043944a /dev-server.cjs | |
parent | e639bedadc81706a522ffe7658fea75300d082f7 (diff) |
Use NODE_ENV to test for test environment; improve scripts
Diffstat (limited to 'dev-server.cjs')
-rw-r--r-- | dev-server.cjs | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/dev-server.cjs b/dev-server.cjs deleted file mode 100644 index 2e7c2ec..0000000 --- a/dev-server.cjs +++ /dev/null @@ -1,27 +0,0 @@ -const { createServer } = require('esbuild-server'); -const server = createServer( - { - bundle: true, - entryPoints: ['src/index.js', 'src/map.js'], - outdir: 'build' - }, - { - static: 'public', - ...(process.argv.slice(2).includes('--test')) && { - port: 3005, - injectLiveReload: false, - watch: false - } - } -); - -const buildStart = Date.now(); -server - .start() - .then(() => { - console.log(`Build completed in ${Date.now() - buildStart}ms`); - }) - .catch(() => { - console.error('Build failed'); - }); -console.log(`Development server running at ${server.url}`); |