2023-03-22 10:07:07 +00:00
|
|
|
import { defineConfig } from 'vite'
|
|
|
|
import baseConfig from './vite.config.js'
|
|
|
|
|
2023-03-28 09:05:58 +00:00
|
|
|
/** see `ports` variable in test-utils.ts */
|
2024-08-01 02:53:07 +00:00
|
|
|
const port = 9525
|
2023-03-28 09:05:58 +00:00
|
|
|
|
2023-03-22 10:07:07 +00:00
|
|
|
export default defineConfig({
|
|
|
|
...baseConfig,
|
2023-03-28 09:05:58 +00:00
|
|
|
base: `http://localhost:${port}/`,
|
|
|
|
server: {
|
|
|
|
port,
|
|
|
|
strictPort: true,
|
|
|
|
},
|
2023-03-22 10:07:07 +00:00
|
|
|
build: {
|
|
|
|
...baseConfig.build,
|
|
|
|
outDir: 'dist/url-base',
|
|
|
|
watch: null,
|
|
|
|
minify: false,
|
|
|
|
assetsInlineLimit: 0,
|
|
|
|
rollupOptions: {
|
|
|
|
output: {
|
|
|
|
entryFileNames: 'entries/[name].js',
|
|
|
|
chunkFileNames: 'chunks/[name]-[hash].js',
|
|
|
|
assetFileNames: 'other-assets/[name]-[hash][extname]',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2023-03-28 09:05:58 +00:00
|
|
|
preview: {
|
|
|
|
port,
|
|
|
|
strictPort: true,
|
|
|
|
},
|
2023-03-28 08:37:38 +00:00
|
|
|
cacheDir: 'node_modules/.vite-url-base',
|
2023-03-22 10:07:07 +00:00
|
|
|
})
|