feat: support some configurations through the .env file

This commit is contained in:
vince
2024-07-09 23:43:08 +08:00
parent 2731a1ec96
commit 2406ca832b
10 changed files with 50 additions and 19 deletions

View File

@@ -31,7 +31,7 @@ function defineApplicationConfig(options: DefineApplicationOptions = {}) {
pwa: true,
turboConsole: false,
...(typeof application === 'function'
? application(config)
? await application(config)
: application),
});
@@ -71,7 +71,7 @@ function defineApplicationConfig(options: DefineApplicationOptions = {}) {
);
return mergeConfig(
mergedConfig,
typeof vite === 'function' ? vite(config) : vite,
typeof vite === 'function' ? await vite(config) : vite,
);
});
}