Reduce admin shell chunk fanout
This commit is contained in:
parent
f44097570d
commit
6726a21e9c
@ -45,6 +45,17 @@ export default defineConfig({
|
|||||||
build: {
|
build: {
|
||||||
modulePreload: false,
|
modulePreload: false,
|
||||||
rollupOptions: {
|
rollupOptions: {
|
||||||
|
output: {
|
||||||
|
manualChunks(id) {
|
||||||
|
// Keep the admin shell dependency graph shallow; GAAP resets the browser HTTP/2 connection when the first screen fans out into many module requests.
|
||||||
|
if (id.includes("node_modules")) {
|
||||||
|
return "vendor";
|
||||||
|
}
|
||||||
|
if (id.includes("/src/shared/") || id.includes("/src/app/")) {
|
||||||
|
return "shared";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
input: {
|
input: {
|
||||||
admin: new URL("./index.html", import.meta.url).pathname,
|
admin: new URL("./index.html", import.meta.url).pathname,
|
||||||
databi: new URL("./databi/index.html", import.meta.url).pathname,
|
databi: new URL("./databi/index.html", import.meta.url).pathname,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user