mirror of
https://github.com/vbenjs/vue-vben-admin.git
synced 2025-08-26 08:36:19 +08:00
perf: pwa icon
This commit is contained in:
@@ -45,10 +45,26 @@ export function createVitePlugins(viteEnv: ViteEnv) {
|
||||
vitePlugins.push(PurgeIcons());
|
||||
|
||||
if (isProdFn() && VITE_USE_PWA) {
|
||||
console.log('======================');
|
||||
console.log(VITE_USE_PWA);
|
||||
console.log('======================');
|
||||
vitePlugins.push(VitePWA());
|
||||
vitePlugins.push(
|
||||
VitePWA({
|
||||
manifest: {
|
||||
name: 'Vben Admin',
|
||||
short_name: 'vben_admin',
|
||||
icons: [
|
||||
{
|
||||
src: './resource/img/pwa-192x192.png',
|
||||
sizes: '192x192',
|
||||
type: 'image/png',
|
||||
},
|
||||
{
|
||||
src: './resource/img/pwa-512x512.png',
|
||||
sizes: '512x512',
|
||||
type: 'image/png',
|
||||
},
|
||||
],
|
||||
},
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
// vite-plugin-mock
|
||||
|
Reference in New Issue
Block a user