mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-04-20 16:47:50 +01:00
Strip console logs from production build
This commit is contained in:
parent
b06c101020
commit
96bafab830
@ -1,7 +1,8 @@
|
|||||||
import { defineConfig } from 'vite';
|
import { defineConfig } from 'vite';
|
||||||
// import fs from 'vite-plugin-fs';
|
// import fs from 'vite-plugin-fs';
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig(({ mode }) => {
|
||||||
|
return {
|
||||||
plugins: [/*fs()*/],
|
plugins: [/*fs()*/],
|
||||||
server: { host: '0.0.0.0', port: 8000 },
|
server: { host: '0.0.0.0', port: 8000 },
|
||||||
clearScreen: false,
|
clearScreen: false,
|
||||||
@ -9,6 +10,8 @@ export default defineConfig({
|
|||||||
minify: 'esbuild',
|
minify: 'esbuild',
|
||||||
},
|
},
|
||||||
esbuild: {
|
esbuild: {
|
||||||
|
pure: mode === 'production' ? [ 'console.log' ] : [],
|
||||||
keepNames: true,
|
keepNames: true,
|
||||||
}
|
}
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user