11 lines
581 B
JavaScript
11 lines
581 B
JavaScript
|
|
import base from '../../../vite.config.js'
|
||
|
|
import {fileURLToPath} from 'node:url'
|
||
|
|
export default context=>{
|
||
|
|
const config=base(context)
|
||
|
|
config.resolve.alias=[{find:/^@\/api\/archive$/,replacement:fileURLToPath(new URL('./mock-api.mjs',import.meta.url))},...Object.entries(config.resolve.alias).map(([find,replacement])=>({find,replacement}))]
|
||
|
|
config.cacheDir='node_modules/.vite-archive-workflow'
|
||
|
|
config.optimizeDeps={...config.optimizeDeps,entries:['tests/ui/archive-workflow/index.html']}
|
||
|
|
config.server={...config.server,port:8091,host:'127.0.0.1',proxy:{}}
|
||
|
|
return config
|
||
|
|
}
|