feat(config): 添加 VITE_CLOUDFLARE_SERVER_ENABLED 环境变量支持
This commit is contained in:
@@ -6,11 +6,12 @@ export function loadPlugin(configEnv: ConfigEnv): PluginOption {
|
||||
const env = loadEnv(configEnv.mode, process.cwd());
|
||||
|
||||
if (configEnv.command === 'build') {
|
||||
consola.info('VITE_ENABLE_VUE_DEVTOOLS is not enabled in build mode.');
|
||||
consola.info('vue-devtools plugin is not used in build mode.');
|
||||
return [];
|
||||
}
|
||||
|
||||
if (env.VITE_ENABLE_VUE_DEVTOOLS === 'true') {
|
||||
if (env.VITE_ENABLE_VUE_DEVTOOLS !== 'true') {
|
||||
consola.info('vue-devtools plugin disabled by env');
|
||||
return [];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user