feat: PWA (#40)

This commit is contained in:
Dream Hunter
2023-12-12 17:26:56 +08:00
committed by GitHub
parent bf6374af52
commit c2c1e4ae59
10 changed files with 3218 additions and 664 deletions
+19
View File
@@ -2,6 +2,7 @@ import { fileURLToPath, URL } from 'node:url'
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import { VitePWA } from 'vite-plugin-pwa'
// https://vitejs.dev/config/
export default defineConfig({
@@ -10,6 +11,24 @@ export default defineConfig({
},
plugins: [
vue(),
VitePWA({
registerType: 'autoUpdate',
devOptions: {
enabled: true
},
manifest: {
name: 'Temp Email',
short_name: 'Temp Email',
description: 'Temp Email - Temporary Email',
icons: [
{
src: '/logo.svg',
sizes: '192x192',
type: 'image/svg+xml'
}
]
}
})
],
resolve: {
alias: {