feat: enhance image loading performance by adding fetchPriority and loading attributes in multiple components, and update MUI icons chunking in webpack configuration

This commit is contained in:
sebseb7
2025-07-20 15:05:29 +02:00
parent d3998133e5
commit a68d912c99
8 changed files with 17 additions and 10 deletions

View File

@@ -223,7 +223,7 @@ export default {
},
// Split commonly used MUI icons (used in main bundle and immediate-loading components)
muiIconsCommon: {
test: /[\\/]node_modules[\\/]@mui[\\/]icons-material[\\/].*(SmartToy|Palette|Search|Home|ShoppingCart|Close|ChevronLeft|ChevronRight|Person|Google|Add|Remove|Delete|KeyboardArrowUp|ZoomIn|Loupe|ExpandMore|ExpandLess|Mic|Stop|PhotoCamera).*\.js$/,
test: /[\\/]node_modules[\\/]@mui[\\/]icons-material[\\/].*(SmartToy|Palette|Search|Home|ShoppingCart|Close|ChevronLeft|ChevronRight|Person|Google|Add|Remove|Delete|KeyboardArrowUp|ZoomIn|Loupe|ExpandMore|ExpandLess|Mic|Stop|PhotoCamera|Menu|KeyboardReturn|ContentCopy|Cancel|CloudUpload|Star).*\.js$/,
name: 'mui-icons-common',
priority: 29,
reuseExistingChunk: true,
@@ -231,7 +231,7 @@ export default {
},
// Split remaining MUI icons into separate chunk (for lazy-loaded components only)
muiIcons: {
test: /[\\/]node_modules[\\/]@mui[\\/]icons-material[\\/]/,
test: /[\\/]node_modules[\\/]@mui[\\/]icons-material[\\/].*(Article|LockReset|AdminPanelSettings|Group|BarChart).*\.js$/,
name: 'mui-icons',
priority: 28,
reuseExistingChunk: true,