fix: 配置 vite.config.js 忽略 UNRESOLVED_IMPORT 告警防止容器构建中断
This commit is contained in:
parent
9c5322b142
commit
8bab17d01e
|
|
@ -17,6 +17,15 @@ export default defineConfig({
|
|||
'@': resolve(__dirname, 'src')
|
||||
}
|
||||
},
|
||||
build: {
|
||||
chunkSizeWarningLimit: 2000,
|
||||
rollupOptions: {
|
||||
onwarn(warning, warn) {
|
||||
if (warning.code === 'UNRESOLVED_IMPORT' || warning.code === 'UNUSED_EXTERNAL_IMPORT') return;
|
||||
warn(warning);
|
||||
}
|
||||
}
|
||||
},
|
||||
server: {
|
||||
//通过电脑ip访问设置
|
||||
host: '0.0.0.0',
|
||||
|
|
|
|||
Loading…
Reference in New Issue